Closed jogo- closed 6 months ago
🤔 Maybe using WASM based Little Endian Base 128 varint encoding / decoding, supporting the full (u)int64 range https://github.com/thi-ng/umbrella/tree/develop/packages/leb128
It should be easy enough to implement in plain JS/TS, their wasm library is nothing magic
Decoding ULEB128 and LEB128 as a full 128 bit integers will be the biggest challenge, as the largest BigInt integer type is limited too. Number.MAX_SAFE_INTEGER = 9007199254740991 Number.MIN_SAFE_INTEGER = -9007199254740991 Or I could try first to decode ULEB128 and LEB128 as sets of up to 16 bytes. @connor4312 What is your opinion?
BigInt is an arbitrary precision integer type and is supported everywhere that VS Code runs
Show in data inspector missing large integer formats as ULEB128 and LEB128 (Little Endian Base 128)