You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
crm-duet.t27 declares two of its functions twice, and the C backend emits the redefinition #4557
specs/automation/crm-duet.t27 declares state_after at lines 206 and 242, and retry_allowed at 201 and 251. The two copies are byte-identical, comment included.
What it costs
t27c check already says it, and has been saying it:
Typecheck OK (0 errors, 2 warnings)
- warning: `fn retry_allowed` is declared 2 times -- every backend rejects a redeclaration
- warning: `fn state_after` is declared 2 times -- every backend rejects a redeclaration
That warning is right, and gen-c still exits 0 and emits both:
cc -std=c11 -fsyntax-only -> error: redefinition of 'state_after'
So the spec generates C that does not compile, and nothing in the chain
stops it: the warning is not an error, and gen-c's exit code does not
reflect it.
Why nobody saw it
Duplicate Body Ratchet fires on pull_request and on push to
master, but the duplicate is on master and the gate is red there — it
shows up only on unrelated PRs that inherit it. Both #4541 and #4551
are failing duplicate-bodies today for this file, which neither of
them touches.
Границы
Only specs/automation/crm-duet.t27. Delete the second copy of each
function; keep the pair at 201/206, which sits with the module's other
function declarations.
Do NOT edit the bodies. They are identical; this is a deletion.
Do not touch tools/dupe_scan.py or its ledger. The scanner is right.
Out of scope, and worth their own issues: gen-c exiting 0 on a spec
it knows every backend rejects, and the emitted header guard #ifndef AUTOMATION::CRM_DUET_H, which is not a valid macro name.
Activity
fix(specs): crm-duet declared two functions twice and the C backend e…