class_docstr: A pure Python implementation of InputStream.
class_docstr_tok: ["A","pure","Python","implementation","of","InputStream","."]
code: def read_var_int64(self):
      shift = 0
      result = 0
      while True:
          byte = self.read_byte()
          if byte < 0:
              raise RuntimeError("VarLong not terminated.")
  
          bits = byte & 0x7F
          if shift >= 64 or (shift >= 63 and bits > 1):
              raise RuntimeError("VarLong too long.")
          result |= bits << shift
          shift += 7
          if not byte & 0x80:
              break
      if result >= 1 << 63:
          result -= 1 << 64
      return result
  
imports: import struct
label_desc: Use image node_id 11 for calling the InputStream obj's underlying member method code with example usage: obj.read_var_int64() and returns: result