Skip to content

Generate node codecs for immutable compiler artifacts - #1

Merged
Frotty merged 1 commit into
masterfrom
codex/immutable-node-codecs
Oct 26, 2026
Merged

Frotty merged 1 commit into
masterfrom
codex/immutable-node-codecs

Conversation

@Frotty

@Frotty Frotty commented Oct 26, 2026

Copy link
Copy Markdown
Member

Incremental compiler artifacts need to freeze owned children separately from external references and metadata. Add a generated NodeCodec for each schema so clients can encode those fields into immutable values and reconstruct private nodes without another handwritten schema table.

The codec is shallow, includes persistent and ignored-equality fields, excludes computed caches, preserves reference-list routing, and rejects unknown kinds or invalid field counts. Clients remain responsible for detached metadata, symbolic keys, and fully resolving declarations before exposing a graph to a pass. This supplies the artifact boundary; it does not itself cache compiler passes or claim a hot-reload speedup.

Validation: 113 generator tests pass on Windows with Java 25 and 27. Six new tests exercise owned children, external and null references, aliasing, mutable metadata, inherited persistent fields, deep bodies, malformed data, and schemas without a type prefix. A reference-as-child mutant makes the recursive-callee test fail with StackOverflowError; the restored producer passes. All four WurstScript schemas generate codecs which compile against the existing compiler classes. Ubuntu/macOS remain unverified locally.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-26T11:46:55.678635Z ffb2b0d PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@Frotty Frotty closed this Oct 26, 2026
@Frotty Frotty reopened this Oct 26, 2026
@Frotty
Frotty merged commit cc63402 into master Oct 26, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant