You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Pratt Parser] Optimize call stack depth via in-place AST mutation and lean dispatch
- In-place AST mutation in binary/ternary operations:
- Updated some Parse* functions to accept ExprNode& lhs and mutate lhs in place instead of returning ExprNode by value.
- Eliminated some intermediate named temporary rhs stack variables.
- Lean ParseUnary and ParsePrimary dispatch:
- Extracted prefix operator parsing (!, -) into ParseUnaryOps(), making ParseUnary() a fast single branch for standard non-prefix expressions.
PiperOrigin-RevId: 963785455
0 commit comments