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
branch still counts the break/continue family: the unconditional transfers #2822 deferred #2832
Deferred residue of #2822 (corollary 3: an unconditional transfer is not a decision) and corollary 2, kept out of that PR to hold one reviewable wave. The contract doc (docs/branch_rule_contract.md) links here.
Corollary 3 residue — the break/continue family.break/continue (c, cpp, csharp, java, javascript, typescript, go, php, dart, apex, kotlin, solidity, zig, powershell, lua, shell, dockerfile-shell, objective-c, ruby next/redo, perl next/last/redo, fortran EXIT/CYCLE, abap EXIT/CONTINUE, ada exit, go fallthrough, livecode next repeat) are unconditional transfers exactly like goto and return, but every rule above still counts them. They were deferred because they are uniform across the C family (so they do not currently break cross-language comparability the way goto did — no corpus cell reads out of band on them) and because the crucible volume is large (c alone: 259 break + 72 continue in the top-8 sample). The fix shape is #2822's: pure de-dup where another rule owns the token, relocation to structural_boundaries otherwise, one golden-master bless.
Corollary 2 residue — the two-keyword loop headers. A C-family do { } while (x) counts 2 (do + while); ada while X loop / for I in ... loop counts 2 (while/for + loop). Both are one construct. Not regex-fixable with a lookbehind (the condition sits between the keywords), so it needs either a paired-token guard in the slicer or a stated design note in the contract sheet. fortran's DO WHILE was fixable (WHILE only ever follows DO there) and was fixed in #2822 itself.
Neither shape currently produces an out-of-band corpus cell; this is crucible-level consistency debt, priced for one session with tests/tools/rule_probe.py before/after snapshots.
Activity
fix(standards): branch counts decisions -- not handlers, closing word…
fix(rules): stop counting unconditional transfers & non-decision toke…
fix(metrics): control_flow_ratio divides by coding LOC, not the bound…
fix(rules): apply test-contract C1/C3 to ruby/js/java/groovy/assembly (…