Repository navigation
COMPILER: delete the dead v1.compiler.* direct-call exemption - #8157
Merged
Merged
Conversation
module_skips_direct_call_arg_check compared a 13-character slice against the 12-character literal "v1.compiler.", so that arm has never returned true for any module. Compiler modules have been receiving the direct-call argument judgment since the arm was written, and the corpus is green under it. Changing 13 to 12 would ACTIVATE an exemption that has never been in force, silencing a judgment the tree currently passes -- a behaviour change dressed as a typo fix, needing evidence of false positives nobody has. Deleting the arm preserves live behaviour exactly and removes both the dead branch and the false claim attached to it: direct_call_shape_wall_note describes this exemption as protecting compiler modules from representation-gap false positives, and that protection was never real. BEHAVIOUR-PRESERVATION RECEIPT, executed rather than argued. A baseline binary built from main's committed generated Rust and this binary were run over the same corpus with the same command, source roots, target and diagnostic projection: baseline 74 diagnostics after 74 diagnostics diff empty (byte-identical sets) regen_stage0 --verify: regen_divergence_count=0. The v2. arm is untouched and does fire. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
gunbai-bot
Bot
force-pushed
the
compiler-applied-nominal-conformance
branch
from
August 11, 2026 21:57
dcd860c to
c3f4e30
Compare
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.
What this is
A one-predicate deletion with an executed behaviour-preservation receipt. It is the surviving half of a larger attempt; the other half was withdrawn on measurement and the finding is below, because it matters more than this commit does.
module_skips_direct_call_arg_checkcompared a 13-character slice against the 12-character literal"v1.compiler.":That arm has never returned true for any module. Compiler modules have been receiving the direct-call argument judgment the whole time, and the corpus is green under it.
Changing
13to12would activate an exemption that has never been in force — silencing a judgment the tree currently passes. That is a behaviour change dressed as a typo fix, and it would need evidence of false positives nobody has. Deletion preserves live behaviour exactly and removes the dead branch together with the false claim attached to it:direct_call_shape_wall_notedescribes this exemption as protecting compiler modules from representation-gap false positives, and that protection was never real.Receipt (executed, not argued)
A baseline binary built from main's committed generated Rust, and this binary, run over the same corpus with the same command, source roots, target and diagnostic projection:
regen_stage0 --verify:regen_divergence_count=0.The
v2.arm is untouched and does fire.Withdrawn: applied-nominal argument conformance, and why
This branch previously carried a second commit implementing resolved applied-nominal direct-call conformance — compare nominal declaration identity, then applied arity, then recurse into applied arguments. It was measured against the same baseline and withdrawn. The measurement is worth keeping:
976 new refusals against 74 baseline diagnostics, with zero confirmed real defects.
The root cause is not tuning. It is that the premise was false. At the
direct_call_arg_mismatch_diagsseam,formalandactualare resolved declarations, andNode.childrenthere holds fields and variants — not applied type arguments. The renderer printed the proof:ContentHashtakes no type parameters. Those are its four variants. So the "applied arity" comparison was comparing field counts and the "recursive argument comparison" was comparing fields. The remaining population was the four false-positive classesdeclared_type_conformance_notealready enumerates — 398 same-declaration-spelled-two-ways (BitWidthvsstd.measure.BitWidth), 477 the same plus aPrimitive(Nat)/Node(Nat)rendering split, 43 optionality's two forms, 58 brand-vs-base pairs and unsubstituted generic variablesT/Mresolving to unrelated same-named declarations.The consequence for the guarantee ladder, stated plainly: a phantom type parameter leaves no trace in the resolved type reaching this seam — the arguments are substituted away into field types before any judgment sees them. So
Point3<RoomFrame>vsPoint3<BuildingFrame>is not merely unjudged here; the information required to judge it is absent at this seam. Deciding that two type references denote the same declaration turns out to be the produced-type-identity problem met from the argument side, not a cheaper neighbour of it — same trigger,feature:conformance-produced-type-identity.That vindicates the separate spatial repair rather than supplementing it: #8156 makes coordinate-frame identity carried runtime data with typed refusal, which is enforceable precisely because it does not depend on a type argument surviving resolution.
A cost note also worth recording: the first implementation peeled both sides through
peel_nominal_alias_identity(which callsresolve_node_bounded) at every comparison level, and took whole-corpus regen from 100 seconds to past 31 minutes. Any future attempt at this seam must treat cost shape as part of the contract.