KCL-Planning / VAL

The plan validation system.
BSD 3-Clause "New" or "Revised" License
106 stars 48 forks source link

VAL's parser: revise to be GLR? #30

Open rpgoldman opened 6 years ago

rpgoldman commented 6 years ago

The parser that VAL uses is pretty badly deformed by the requirements of yacc-style LR(1) parsing. Instead of being a clean(ish) copy of the grammar from the spec, it's had to be hand-compiled into something that meets those requirements. That means that it can be very difficult to maintain or extend. I was wondering: bison now supports generalized LR (GLR) parsing, which permits some ambiguities that standard yacc parsing couldn't handle (hence the extensive hand-compiling). This suggests that it might be a good idea to make a version of the parser that uses GLR parsing to improve maintainability. Does this sound reasonable? Aside, that is, from finding someone who wants to do it!