Repository navigation
compiler direction - #9502
Closed
briansrls wants to merge 1 commit into
Closed
compiler direction#9502briansrls wants to merge 1 commit into
briansrls wants to merge 1 commit into
Conversation
…aking it computable
THE DEFECT, STATED AT THE GRAIN THE MEASUREMENT SUPPORTS. `TransitionAdmission.subject` was
`DeltaSubject`, whose fields are `String` because it is built at runtime from discovered module
names. The roster is a `const`. Measured against those exact types, both arms:
module: String::from("probe.consumer") -> error[E0015]: cannot call non-const associated
function <String as From<&str>>::from in constants
-- three times, one per field
module: String::new() -> compiles clean, emits metadata
So the roster was NOT uninhabitable, and an earlier statement of this defect (mine) said it was.
It held exactly one shape -- every field the empty string -- and that shape matches no delta. What
no const row could do was NAME A REAL MODULE: a hatch with no working position.
WHAT IT WAS NOT. A row authored anyway does not silently pass. It matches nothing, lands in
`stale_admissions`, prints with its own cause, and the ADMITTED arm is conjoined on that list being
empty -- so it REFUSES. An earlier report of this as an escape hatch that accepts rows and silently
matches nothing was withdrawn at source. Both failure paths were always loud; only the admission
arm was fiction (§4b -- decoration cited as coverage, inside an otherwise real wall).
THE FIX KEEPS CONST-NESS, WHICH IS DOING UNNAMED SAFETY WORK. A const roster cannot be COMPUTED, so
no code path can synthesise an admission: the admission set is exactly what a human authored and a
reviewer read. Reaching for a function or a `LazyLock<Vec<_>>` restores authorability by making
admissions computable, which is the absorbing fallback arriving through a type signature -- the
module's own header already forbids its behavioural twin, an admission "by a predicate ... which
admits everything and zeroes the wall's deficit frequency by construction". So admission rows get
their own `AdmissionSubject` with `&'static str` fields, matched against the runtime `DeltaSubject`.
That is also the better §3 statement: an admission row's subject is a PATTERN naming one subject,
not a subject.
WHY THE EXISTING COVERAGE COULD NOT SEE THIS, and it is the part worth keeping. Two thorough tests
already exercised the admission path -- exact-match admits, wrong-subject refuses and reports stale
-- and both build their rows in a `let` with `.to_string()`. Neither ever touched the `const`
constraint that actually bound production. So an auditor reading the admission path found green,
careful evidence about a mechanism no authorable production row could reach: the coverage made the
defect MORE hidden, not less.
a_row_authored_in_a_const_admits_its_delta_exactly_as_a_runtime_row_would
a_row_naming_the_empty_module_refuses_rather_than_admitting_silently
The first one's discriminating property is COMPILATION at a real module name, which is what the old
type refused. The second asserts the stale report BY LABEL, because an unattributable refusal is
close to the defect being fixed. Both stay enrolled after the climb rather than dissolving with it
(§4b -- a climb deletes the redundant production machinery, never the evidence).
22/22 green.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Contributor
|
Closing: this PR was created automatically from a pushed branch, not by me, and it should not exist. The branch The change itself is real and verified (22/22 green, fmt clean); it lands via #9436. — sent from warm-hawk-909 |
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.
Auto-opened by session-dashboard for session
warm-hawk-909.Pushing to
fix/admission-roster-inhabitableadvances this PR.Worker attestation
Before flipping this PR to ready for review, confirm each item:
npm test,cargo test) and the result.Closes #Ndirective.Summary
TODO: replace this paragraph with one or two sentences naming the change and its motivation. Reviewers read this first.
Test plan