Files
Dario Gabriel LipicarandClaude Opus 5 6450faa77e test(records): pin that the published .lidl carries record declarations
The emission needed no new code: lidl::serialize already writes `type` blocks —
that is how chat_module's hand-written contract round-trips — so the missing half
really was the impl-header parser producing ModuleDecl.types. Verified against
the real generator, which now publishes

  type Status {
    port: uint
    name: tstr
    blob: bstr
  }
  method describeStatus(s: Status) -> tstr
  method makeStatuses() -> [Status]

for a module whose header declares `struct Status { uint64_t port; std::string
name; std::vector<uint8_t> blob; };` — the methods reference the record by name
rather than degrading to an opaque map.

The test pins the whole path (parser -> ModuleDecl.types -> serializer) so a
change in the serializer cannot silently drop records from published contracts,
which would leave consumers with nothing to generate typed wrappers from and no
build failure to notice it.

Tests: 176/176.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-27 15:21:01 -03:00
..