Skip to content

fix(gen-zig): a module-scoped type maps like its bare name (owner exception, #5980) - #6599

Merged
gHashTag merged 5 commits into
masterfrom
claude/gen-zig-spliced-type
Oct 5, 2026
Merged

gHashTag merged 5 commits into
masterfrom
claude/gen-zig-spliced-type

Conversation

@gHashTag

@gHashTag gHashTag commented Oct 5, 2026 •

Copy link
Copy Markdown
Owner

Closes #6533

What

A struct spliced in by use kept a module-scoped type, gf16::GF16, as gf16.GF16. The generated Zig never declares that name, so the file did not compile. The Zig type mapper now maps a module-scoped type the same way as its bare name (gf16::GF16 -> u16). specs/compiler/zig_scoped_type.t27 is the regression spec.

Owner exception

This PR edits hand-written Rust (bootstrap/src/compiler.rs), which the only-t27 rule forbids. The owner approved it on 2026-10-05, relayed by the coordinator ("fix it and do not stop, do what is best"), with the label owner-approved-foreign. The debt is #5980 (t27core self-host). This PR does not change tools/policy/foreign-exceptions.txt. The entries bootstrap/src/compiler.rs and bootstrap/tests/bare_semicolon_zig.rs are already on master from #6579. They stay for the remaining gen-zig classes the owner listed (generic T undeclared, math.*, expected ',' after field). When those land, or are dropped, the owner should remove the entries.

File classification

File(s) Kind
bootstrap/src/compiler.rs hand-written Rust, owner exception (#5980)
bootstrap/stage0/FROZEN_HASH derived: sha256 of compiler.rs
specs/compiler/zig_scoped_type.t27 .t27 regression spec
.trinity/seals/*.json (16) generated on the Railway t27c lab (tri seals drift --fix, tri seals sync-twins)
docs/now/2026-10-06-gen-zig-scoped-type.md NOW prose

Lab numbers (t27c reference: gen-zig + zig test over specs/, Railway t27c lab)

run sha pass blocked fail timeout
before: #6596's head 485e388 776 472 35 4
this PR, on that base 6eecfc0 777 472 35 4
  • The new spec passes. 0 regressions. No other spec changes verdict: ml/transformer/multi_head_attention.t27 gets past this error and stops at its next one, so it stays blocked.

Seals

Seals were regenerated on the lab. On the lab, check_seal_currency passes and check_seal_coverage reports OK (1454 seals, 1310 hold, 144 known-broken).

CI notes

The expected failures match master: test-ratchet (the_dead_code_census_names_what_it_skipped and corpus_classifier_matches_lean_completeness), spec-guards (ring-096-rust DRIFTED, #6553), duplicate-bodies, fpga-conformance, and build-and-test (cargo install wasm-objdump).

🤖 Generated with Claude Code

gHashTag and others added 3 commits October 6, 2026 02:11
Closes #6533

A spliced struct kept gf16::GF16 as gf16.GF16, which the generated Zig does not
declare. The Zig type mapper now maps a module-scoped type like its bare name
(gf16::GF16 -> u16). specs/compiler/zig_scoped_type.t27 is the regression spec.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Refs #6533

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Refs #6533

Regenerated on the Railway t27c lab (tri seals drift --fix, sync-twins);
check_seal_currency and check_seal_coverage pass there.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@gHashTag gHashTag added the owner-approved-foreign Owner-approved exception to the only-t27 rule: hand-written foreign code allowed in this PR label Oct 5, 2026
@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-05 19:13:59 UTC

Summary

Status Count
Total Open PRs 46
PRs with Failing Checks 33
PRs with All Checks Green 13
READY 11
FAILING 33
PENDING 0
NO CHECKS YET 0

These columns do not partition: 11 + 33 + 0 + 0 = 44, and there are 46 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=3c78f3c7ffb7 != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-05 22:04:11 UTC

Summary

Status Count
Total Open PRs 50
PRs with Failing Checks 37
PRs with All Checks Green 13
READY 12
FAILING 37
PENDING 0
NO CHECKS YET 0

These columns do not partition: 12 + 37 + 0 + 0 = 49, and there are 50 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=3c78f3c7ffb7 != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-05 22:18:50 UTC

Summary

Status Count
Total Open PRs 50
PRs with Failing Checks 37
PRs with All Checks Green 13
READY 12
FAILING 37
PENDING 0
NO CHECKS YET 0

These columns do not partition: 12 + 37 + 0 + 0 = 49, and there are 50 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=3c78f3c7ffb7 != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

@gHashTag
gHashTag merged commit 5def1c8 into master Oct 5, 2026
33 of 37 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

owner-approved-foreign Owner-approved exception to the only-t27 rule: hand-written foreign code allowed in this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

t27c use-resolve: a spliced struct keeps gf16::GF16 as gf16.GF16, so the generated Zig does not compile

1 participant