MCPcopy Create free account
hub / github.com/Textualize/textual / decode_int

Function decode_int

src/textual/_binary_encode.py:229–238  ·  view source on GitHub ↗

Decode an int from the encoded data. Returns: An integer.

()

Source from the content-addressed store, hash-verified

227 return bytes_data
228
229 def decode_int() -> int:
230 """Decode an int from the encoded data.
231
232 Returns:
233 An integer.
234 """
235 int_bytes = b""
236 while (byte := get_byte()) != b"e":
237 int_bytes += byte
238 return int(int_bytes)
239
240 def decode_bytes(size_bytes: bytes) -> bytes:
241 """Decode a bytes string from the encoded data.

Callers

nothing calls this directly

Calls 1

get_byteFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…