feat(ctx-symbol): Anchor compact folds at AST body nodes and drive corpus regressions to zero - #24
Merged
Conversation
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.
Verdict: found already landed + one gap fixed
The M1 plan's core (
Language::body_node_kinds(),find_body_node,fold_at_body_node) was already merged via earlier PRs (#13 et seq.) — not re-implemented. This delta re-measured the corpus, found and fixed the single remaining failure class, and closed out docs.Baseline (branch @ 6cd7836)
All h/hpp/go/py classes from the original ~5.3k baseline were already at zero.
Fix
/* ... [N lines omitted]without the closing*/; the unterminated comment swallowed the kept}and every folded rule set failed to re-parse. Fix appendsLanguage::comment_close()infold_at_body_node(no-op for line-comment backends). Commit:fix(ctx-symbol): fold css rule sets at their AST body (css).css_rule_set_fold_keeps_block_comment_closed.compact_output_is_byte_stable_across_invocationspinning byte-identical output across two invocations over all fold paths.files: 55498 raw-parse-ok slices: 1879020 regressions: 0.Gates
cargo fmt --check / clippy --all-features --all-targets -D warnings / cargo test — all green (13 suites).
Report: https://github.com/Xuepoo/ctxctl-docs/pull/2