gen-zig: skip dead base-types import; test asserts panic instead of compileError - #1929
Merged
Conversation
…ompileError Two fixes unlocking the zig-test EXECUTION level over tri-net's gens: 'use base::types' emitted an @import of a never-shipped types.zig even with zero references, failing every file before a single test ran (the import now emits only when referenced); and test asserts used @CompileError, which fires whenever a runtime-condition branch is analyzed -- @Panic(msg) is the honest runtime failure and still dies at comptime when the condition folds false. tri-net sweep: 4/69 -> 37/69 files compile AND pass their test blocks; the rest are REAL findings (the t27 saturation idiom needs +%, genuine runtime failures, two small tails) tracked in the issue. Unit suite 1537/1537; FROZEN_HASH resealed. Refs #1928 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
gHashTag
enabled auto-merge (squash)
August 8, 2026 10:11
Contributor
|
📓 NotebookLM Notebook linked to this PR
This notebook contains session context, decisions, and artifacts for this work. |
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Unlocks the
zig testEXECUTION level over tri-net's committed gens (a level above ast-check). Two fixes: (1)use base::typesemitted an @import of a never-shipped types.zig even with ZERO references -- every generated file failed with FileNotFound before a single test ran; the import now emits only when the module body references it. (2) Test asserts emitted@compileError, which fires whenever a runtime-condition branch is ANALYZED --@panic(msg)is the honest runtime failure and still dies at comptime when the condition folds false.tri-net sweep: 4/69 -> 37/69 gens compile AND pass their test blocks. The remaining 32 are REAL findings the execution level exists to catch (the t27 saturation idiom
sum = a + b; if (sum < a)is Zig-fatal at the checked+-- needs+%; genuine runtime test failures like etx's dead-link case; two emission tails) -- tracked in #1928, ratcheting in tri-net. Unit suite 1537/1537; FROZEN_HASH resealed; NOW files updated.Refs #1928
🤖 Generated with Claude Code