Repository navigation
Commit b0d96c4
committed
fix: use map module order for checkSplit order-constraint filter
orderConstraints filters out constraint pairs where the binding's statement
index exceeds the reader's, which correctly reflects source order when
analyzing the original unsplit file. checkSplit instead analyzes the joined
text from joinClientRuntime, where modules are concatenated in chain
evaluation order. When the chain inverts two modules relative to the
original source, the binding appears after the reader in the joined text,
the filter removes the pair, and the order violation goes undetected.
Fix by computing a sourceOrder mapping from the map's module order (which
mirrors the original single-file layout) and passing it to
orderConstraints. Within each module the joined text preserves the original
statement order; the map's module rank provides the correct inter-module
ordering. When the map is unavailable (e.g., test fixtures), the filter
falls back to the joined text order.1 parent fdaf44b commit b0d96c4
1 file changed
Lines changed: 22 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
666 | 666 | | |
667 | 667 | | |
668 | 668 | | |
669 | | - | |
| 669 | + | |
670 | 670 | | |
671 | 671 | | |
672 | 672 | | |
| |||
684 | 684 | | |
685 | 685 | | |
686 | 686 | | |
687 | | - | |
| 687 | + | |
| 688 | + | |
| 689 | + | |
688 | 690 | | |
689 | 691 | | |
690 | 692 | | |
| |||
813 | 815 | | |
814 | 816 | | |
815 | 817 | | |
| 818 | + | |
| 819 | + | |
| 820 | + | |
| 821 | + | |
| 822 | + | |
| 823 | + | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
| 828 | + | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
816 | 835 | | |
817 | 836 | | |
818 | 837 | | |
| |||
825 | 844 | | |
826 | 845 | | |
827 | 846 | | |
828 | | - | |
| 847 | + | |
829 | 848 | | |
830 | 849 | | |
831 | 850 | | |
| |||
0 commit comments