Skip to content

Bundle 5: registry facades and zero-unsafe UATs for lz4, libsodium, expat, libyaml - #3668

Merged
ehartford merged 7 commits into
mainfrom
bundle5-facades
Nov 28, 2026
Merged

ehartford merged 7 commits into
mainfrom
bundle5-facades

Conversation

@ehartford

Copy link
Copy Markdown
Contributor

Completes four sibling C library registry facades and zero-unsafe UATs under Epic #3115, bundled under one seed-driven battery:

  • WCL D247 (buffer param P len|capacity param L updates [elements]): supports streaming in-out buffer counts (LZ4F_decompress, LZ4F_getFrameInfo, LZ4_compress_destSize), bounds-checked after C returns and returned in the result tuple.
  • WCL D248 (buffer param P len|capacity <N> and capacity param L +/- <N>): supports fixed-size and offset-derived crypto/protocol buffers (libsodium, expat, openssl). Also carries numeric reads param N items in CiFacts.with.
  • WCL D249 (init F(param N), ok K + bridged init rendering): supports positioned in-place initializers (yaml_parser_parse, yaml_parser_load, yaml_parser_scan) and full parameter-bridge prologues (buffer, nullable, text, reads) on in-place init constructors. Also aligns SemaFacade nullable validation with FacadeRender for text param.
  • WCL D250 (retains param N by param 0 for paired buffer/value params): hooks non-variadic buffer and updates/reads retentions (up to two retained parameters per setter, e.g. yaml_parser_set_input_string, yaml_emitter_set_output_string) into MIR's FOREIGN_PAIR_RETAIN CFG checker with Copy scope-exit StorageDead tracking.
  • c.lz4 (Registry facade for c.lz4 (compression): complete, reviewed, with a zero-unsafe UAT #3137): complete registry/c/lz4/facts.with (38/38 safe) + zero-unsafe uat/lz4.uat (block default/HC, LZ4F streaming frame compress & 64-byte chunked decompress).
  • c.libsodium (Registry facade for c.libsodium (crypto): complete, reviewed, with a zero-unsafe UAT #3142): complete registry/c/libsodium/facts.with + zero-unsafe uat/libsodium.uat (sodium_init, randombytes_buf, secretbox, box seal/open, sign detached/verify, pwhash, sodium_memzero/sodium_is_zero).
  • c.expat (Registry facade for c.expat (XML): complete, reviewed, with a zero-unsafe UAT #3148): upgraded registry/c/expat/facts.with to c facts (69/86 safe) + zero-unsafe uat/expat.uat (3-chunk streaming XML_Parse with start/end/cdata callbacks, XML_UseParserAsHandlerArg, status/property queries, malformed XML error position reporting).
  • c.libyaml (Registry facade for c.libyaml (YAML): complete, reviewed, with a zero-unsafe UAT #3149): complete registry/c/libyaml/facts.with (42/48 safe) + zero-unsafe uat/libyaml.uat (yaml_parser_parse event loop, yaml_emitter_emit round-trip with exact event-sequence verification, and Document + yaml_emitter_dump).

Closes #3137
Closes #3142
Closes #3148
Closes #3149

Draft until the seed-driven battery on the top commit is green.

@ehartford

Copy link
Copy Markdown
Contributor Author

Seed-driven battery on 007911cfe is GREEN (rc=0, wall 1027s):

out/battery/battery.log: rc=0 green

All 27 runnable UAT scenarios passed (1 Windows-only skip), including lz4, libsodium, expat, libyaml, and zlib, and internals-tests (144/144) + behavior-tests (2353/2353) + stage2 == stage3 fixpoint are green.

@ehartford
ehartford marked this pull request as ready for review November 28, 2026 03:13
@ehartford
ehartford merged commit 40fb49b into main Nov 28, 2026
1 check passed
@ehartford
ehartford deleted the bundle5-facades branch November 28, 2026 03:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant