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
What's the canonical way to define nested structures such as arrays, parentheses, etc?
Something as simply as "(" ~ EXPR ~ ")" will crash if you put enough ( in a row - in my grammar 30 or so is enough
There is always the call limit but since it does not lower back down as the depth goes down, and since there is -no way- to reset the counter, it's mostly useless for parsing larger inputs
So What's the best way to parse these things? My array definition is below for reference:
I can overflow the stack with [[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
What's the canonical way to define nested structures such as arrays, parentheses, etc?
Something as simply as
"(" ~ EXPR ~ ")"
will crash if you put enough(
in a row - in my grammar 30 or so is enoughThere is always the call limit but since it does not lower back down as the depth goes down, and since there is -no way- to reset the counter, it's mostly useless for parsing larger inputs
So What's the best way to parse these things? My array definition is below for reference:
I can overflow the stack with
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
Beta Was this translation helpful? Give feedback.
All reactions