Commit 57b4c3b
fix: guard infix reassociation against malformed operands
Recent fn-head parsing changes introduced infix reassociation branches that assume comma/when operands always carry list arguments. In the absinthe matrix CI run, a malformed intermediate AST used , which passed the guard and crashed in .
This change hardens the parser by requiring list operands before reassociation in , and by making fn-head nested-parens validation a no-op for non-list argument payloads.
This preserves existing behavior for valid AST shapes while preventing parser crashes on recoverable malformed intermediates encountered during large real-world repo parsing.1 parent 76931b3 commit 57b4c3b
1 file changed
Lines changed: 5 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1357 | 1357 | | |
1358 | 1358 | | |
1359 | 1359 | | |
1360 | | - | |
| 1360 | + | |
1361 | 1361 | | |
1362 | 1362 | | |
1363 | 1363 | | |
| |||
1375 | 1375 | | |
1376 | 1376 | | |
1377 | 1377 | | |
| 1378 | + | |
| 1379 | + | |
1378 | 1380 | | |
1379 | 1381 | | |
1380 | 1382 | | |
| |||
1569 | 1571 | | |
1570 | 1572 | | |
1571 | 1573 | | |
1572 | | - | |
| 1574 | + | |
1573 | 1575 | | |
1574 | 1576 | | |
1575 | 1577 | | |
1576 | | - | |
| 1578 | + | |
1577 | 1579 | | |
1578 | 1580 | | |
1579 | 1581 | | |
| |||
0 commit comments