For the complete documentation index, see llms.txt. This page is also available as Markdown.

Raw data layout

raw-data-layout.gpc
// Byte offsets: 0, 1, 2, 3, 4, 5, 6, 7
data(0xFF, 0x7F, 0x34, 0x12, 0x78, 0x56, 0x34, 0x12);

int a, b, c, d, e;

main {
    a = dint8(0);   // -1
    b = duint8(0);  // 255
    c = dint16(2);  // signed 16-bit from bytes 2..3
    d = duint16(2); // unsigned 16-bit from bytes 2..3
    e = dint32(4);  // signed 32-bit from bytes 4..7
}

The reader index is a byte offset. Wider entries and values shift all later offsets. Use a layout table beside nontrivial packed data.

Last updated