Repository navigation
Nim: stop counting try/except/finally as branches (Part of #8863) - #9017
squid-protocol wants to merge 1 commit into
Conversation
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
|
No description provided. |
|
No description provided. |
|
PR #9017 @ 30ce1a5: 1 failed check(s) == graph-accuracy-audit (failure) -- real |
|
Waiting on an owner decision (asked privately, 2026-11-22). Nothing is needed from contributors; work resumes once it is answered. |
|
Superseded by #8939 (the branch / short_circuit family split), which already removes try/except/finally from Nim's |
Summary
Nim
branchno longer countstry,exceptorfinally: the branch contract's corollary 1 says a handler is not a decision, andsafety(same file) already owns all three. Fixes #8926 (part of #8863).Class / Sibling gaps
Class: exception-handler keywords (
try/except/finally) counted in a language'sbranchrule. In this PR: Nim, the whole keyword set (try,exceptincl. bare andexcept X as e,finally), tested nested insideif, in strings/comments, and withsafetystill counting them. Not in this PR (the issue's other items, other mechanism): Nim booleanand/or(#8905),proctype scored as a closure, standalone##comment credited as a doc.Sibling gaps found by a one-line grep of
languages/*.pybranch rules (multi-line rules not swept): elixir.py (try|rescue|catch), erlang.py (try|catch), julia.py (try|catch|finally), ocaml.py (try). Each needs its own contract decision and golden/rosetta re-bless, so not done here.Evidence
tests/extraction/languages/test_nim_strict.py: 13 passed (newtest_handlers_are_not_branches_8926).crucible_check.py --update --yesvia golden-lock: no drift in either golden (the crucible Nim files have no handler); no re-bless needed.rosetta:rebless-owednot expected from the crucible, but the rosetta Nim control was not run here.pr_gates --fast9/9 pass;--ratchets9 pass, 0 fail, 0 skipped.Cross-repo
None. Rosetta (keyword-rosetta) Nim counts may move: re-run its sweep after merge.
🤖 Generated with Claude Code