Skip to content

fix(WO17): override rows join the trailing parallel pass — cross-grammar parity - #842

Merged
ronaldtse merged 1 commit into
mainfrom
wo17/py-override-placement
Nov 11, 2026
Merged

ronaldtse merged 1 commit into
mainfrom
wo17/py-override-placement

Conversation

@ronaldtse

Copy link
Copy Markdown
Contributor

Summary

The first run of the cross-grammar parity harness (maps scripts/parse-parity.mjs, PR #270) caught interscript-py appending unmatched override additions as bare stage rules while the ruby reference and the ts runtime join ALL override rows into the trailing parallel block (§4.2.6): bgnpcgn-tha compiled 344 vs 327+17, alalc-tha 1523 vs 327+1196 — the additions ran as separate sequential gsubs instead of participating in the single longest-match pass they extend.

_apply_override now mirrors the canonical merge: partition by byte-exact from-equality; when the expansion ends with a parallel block, ALL of O joins it; otherwise O appends as stage-level rows.

Verification

  • Two placement specs watched failing first (one pass item; kept-then-overrides order ["b","a","c"]; one-pass execution "ac" → "AZ").
  • Suites green post-fix: wf1, parser, constraints, and the golden additivity test — 12,337 rows byte-identical through the in-process py runtime, in-suite.

…- cross-grammar parity

The first run of the cross-grammar parity harness (maps
scripts/parse-parity.mjs) caught interscript-py appending unmatched
override additions as bare stage rules while ts/ruby join ALL
override rows into the trailing parallel block (§4.2.6) - bgnpcgn-tha
compiled 344 vs 327+17, alalc-tha 1523 vs 327+1196: the additions ran
as separate sequential gsubs instead of participating in the single
longest-match pass with the rows they extend.

_apply_override now mirrors the canonical merge: partition R by
byte-exact from-equality, then when the expansion ends with a
parallel block ALL of O joins it; otherwise O appends as stage-level
rows. Two placement specs watched failing first (one item, kept-then-
overrides order, one-pass execution). Suites: wf1/parser/constraints
green; the golden (12,337 rows, in-process) green in-suite.
@ronaldtse
ronaldtse merged commit 7a84260 into main Nov 11, 2026
13 checks passed
@ronaldtse ronaldtse mentioned this pull request Nov 12, 2026
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