Skip to content

A discarded modifier with no consumer is latent, not wrong - #2881

Merged
gHashTag merged 1 commit into
masterfrom
w731
Aug 29, 2026
Merged

A discarded modifier with no consumer is latent, not wrong#2881
gHashTag merged 1 commit into
masterfrom
w731

Conversation

@gHashTag

Copy link
Copy Markdown
Owner

A parser audit found two modifiers consumed and recorded nowhere: pub on a struct field (41 sites) and the ! error-union marker on a return type (4). Both are the shape of #2867 — where the lexer advanced past u64 and stored nothing — and that one was a defect, because the Zig shift path then re-invented the width and a function panicked at run time.

These two are not, and the difference is one question: does anything downstream read it?

  • The Rust backend emits pub on every struct field regardless of the spec; Zig has no field visibility; C has none. Three of three produce identical output either way.
  • Of the four ! sites, three are bodiless declarations ending in ; that no backend emits, and the fourth is Zig's noreturn ! — a different construct sharing a token.

Grep count 45. Live consequence 0.

The count is not the finding. For a lost piece of information the finding is the consumer, and looking for one costs two commands: generate the output both ways and diff. Without that, a report reads "45 sites" and sounds like the CORDIC shift — which was 376 sites and a wrong gate on silicon.

What to do with a latent one: record it, say plainly that nothing reads it today, and say where to look on the day something does. Filed as #2880. Fixing it means adding a field nothing consumes — a change with no measurement that could show it worked.

Refs #2880

A parser audit found `pub` on a struct field (41 sites) and the `!`
error-union marker (4) both consumed and recorded nowhere -- the shape of
#2867, where the lexer dropped a width suffix and the Zig shift path then
re-invented it and a function panicked.

These two are not defects today, and the difference is one question: does
anything downstream read it? The Rust backend emits `pub` on every field
regardless, Zig and C have no field visibility, and three of the four `!`
sites are bodiless declarations no backend emits while the fourth is
noreturn. Grep count 45, live consequence 0.

The count is not the finding. For a lost piece of information the finding
is the consumer, and looking for one costs two commands: generate the
output both ways and diff it. Without that a report reads "45 sites" and
sounds like the CORDIC shift, which was 376 sites and a wrong gate on
silicon.

Refs #2880
@gHashTag
gHashTag enabled auto-merge (squash) August 29, 2026 20:17
@github-actions

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-08-29 20:17:39 UTC

Summary

Status Count
Total Open PRs 9
PRs with Failing Checks 7
PRs with All Checks Green 2
READY 1
FAILING 7
PENDING 0

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=5958d7f24cb2 != 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

Copy link
Copy Markdown
Contributor

📓 NotebookLM Notebook linked to this PR

This notebook contains session context, decisions, and artifacts for this work.

@gHashTag
gHashTag merged commit a08ab9c into master Aug 29, 2026
23 of 24 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