Files
zeekay 227ba53f3c The Q-chain reads and writes the wire a schema states
chains/schema/qchain.zap says what a Q block and a Q transaction are — the
same offsets the chain stated in Rust, and the same ones the Go chain writes.
zapgen turns that into the accessors, so the block and the two transaction
shapes are no longer spelled out twice.

The runtime goes with them. chains/rust/zap holds one emitted copy for every
chain in this directory, so the reader a chain calls is the reader the Go and
C++ chains call; quantumvm's own 896-line copy is gone, and xvm's byte-
identical twin will follow.

What is left in wire.rs is what a Q block MEANS: the transaction set a length
list partitions, the bound on how much a peer can make this node allocate,
and canonical-or-nothing — re-serializing what was decoded and refusing
anything that does not come back the same bytes.

The bytes did not move. The two Go-captured golden wires still match, and
tests/corpus_bytes.rs now writes back every Q block in the shared corpus and
compares it to the hex the Go chain generated: 12 blocks, byte for byte.
110 unit tests, the corpus differential and the byte test all pass.

One verdict moved and it moved tighter. A reader that knows an element is
four bytes wide now refuses a declared count no buffer that size could hold,
so a forged length list is refused where it is read instead of at the
allocation behind it. The allocation bound is still there and still catches
the counts that fit the run but not the blob; the test now names both.
2026-09-06 13:54:24 -07:00
..