Module debris_parser::parser
source · Structs
- Options passed to the parsers recover function
Functions
- This function implements a hack that combines a minus token with an int token. This is not done in general, because this behavior should not be exhibited in all places. E.g.
a-2
should not parse a negative number literal. - Looks forward and checks if the current item can be an update. This is a hack to resolve the statement-ambiguity where both of expr and update are valid. For example,
(a, b, c)
could be parsed as a tuple or as a pattern for an update. - Parses a comma separated list of items Returns a tuple of (
number_of_items
,number_of_commas
) - Parses a single prefix
- Parses leading prefix operators and control flow operators and returns whether a prefix was parsed
- Parses a statement