bscotch / stitch

Tools and apps for GameMaker development: a CLI for pipeline development, a VSCode extension for coding, and more.
Other
119 stars 13 forks source link

The parser can recover from syntax errors, but the visitor can crash on recovered nodes #99

Closed adam-coster closed 1 year ago

adam-coster commented 1 year ago

The parser is set up to be robust to syntax errors, but recovery can result in nodes that do not follow the expected types. The visitor/processor accounts for some recovery situations, but not all, and throws uncaught errors upon new recovery scenarios. This fully crashes the parser (and, subsequently, the VSCode extension).

To make things more robust, file-level processing should catch thrown errors and still emit diagnostics.