UNPKG

@bare-ts/lib

Version:

TypeScript library for BARE, a compact and simple binary-serialization format

9 lines (8 loc) 533 B
import type { ByteCursor } from "../core/byte-cursor.ts"; export declare function readUint(bc: ByteCursor): bigint; export declare function writeUint(bc: ByteCursor, x: bigint): void; export declare function writeUintTruncated(bc: ByteCursor, x: bigint): void; export declare function readUintSafe32(bc: ByteCursor): number; export declare function writeUintSafe32(bc: ByteCursor, x: number): void; export declare function readUintSafe(bc: ByteCursor): number; export declare function writeUintSafe(bc: ByteCursor, x: number): void;