Instead of just manually calling .oneOf and branching on the list of tokens, it would be more ergonomic to have a function (pseudo signature, the types don't have to be exact)map<ParserFunc, R>(vec![(Token, ParserFunc)]) where ParserFunc: FnOnce(p: &mut Parser) -> R:
This issue was generated by todo-issue based on a TODO comment in 5153249faabb44a3dca98ecdaa5840ca2cf139c7. It's been assigned to @sezna because they committed the code.
Instead of just manually calling
.oneOf
and branching on the list of tokens, it would be more ergonomic to have a function (pseudo signature, the types don't have to be exact)map<ParserFunc, R>(vec![(Token, ParserFunc)]) where ParserFunc: FnOnce(p: &mut Parser) -> R
:https://github.com/sezna/petr/blob/5153249faabb44a3dca98ecdaa5840ca2cf139c7/petr-parse/src/parse_to_ast.rs#L271-L275
This issue was generated by todo-issue based on a
TODO
comment in 5153249faabb44a3dca98ecdaa5840ca2cf139c7. It's been assigned to @sezna because they committed the code.