Commit 4f65764
committed
feat: Add FoldPostfix command and Haxe grammar for for-range loops
- Add FoldPostfix command to runtime for handling postfix expression chains
- Implement fold_postfix JSON command parsing in ZynPEG runtime
- Add create_range and apply_postfix methods to AstHostFunctions trait
- Add haxe.zyn grammar with support for classes, methods, control flow
- Desugar for-in loops with Range expressions to while loops
- Fix stack pollution issue where unrecognized commands left stale values
This enables parsing Haxe for loops like `for (j in 0...5) { }` and
correctly desugaring them to equivalent while loops.1 parent 5b6dd30 commit 4f65764
3 files changed
Lines changed: 1293 additions & 11 deletions
0 commit comments