parameters: (buffer, pos)
return_statement: return (buffer[start:pos], pos)
docstring: Read a tag from the buffer, and return a (tag_bytes, new_pos) tuple.
  
    We return the raw bytes of the tag rather than decoding them.  The raw
    bytes can then be used to look up the proper decoder.  This effectively allows
    us to trade some work that would be done in pure-python (decoding a varint)
    for work that is done in C (searching for a byte string in a hash table).
    In a low-level language it would be much cheaper to decode the varint and
    use that, but not in Python.
docstring_summary: Read a tag from the buffer, and return a (tag_bytes, new_pos) tuple.
docstring_tokens: Read a tag from the buffer and return a ( tag_bytes new_pos ) tuple .
function: def ReadTag(buffer, pos):
    """Read a tag from the buffer, and return a (tag_bytes, new_pos) tuple.
  
    We return the raw bytes of the tag rather than decoding them.  The raw
    bytes can then be used to look up the proper decoder.  This effectively allows
    us to trade some work that would be done in pure-python (decoding a varint)
    for work that is done in C (searching for a byte string in a hash table).
    In a low-level language it would be much cheaper to decode the varint and
    use that, but not in Python.
    """
  
    start = pos
    while ord(buffer[pos]) & 0x80:
      pos += 1
    pos += 1
    return (buffer[start:pos], pos)
function_tokens: def ReadTag ( buffer , pos ) : start = pos while ord ( buffer [ pos ] ) & 0x80 : pos += 1 pos += 1 return ( buffer [ start : pos ] , pos )