AzureMarker / intellij-lalrpop

Jetbrains plugin for the LALRPOP parser-generator
MIT License
16 stars 2 forks source link

Infer the right type on fallible actions #23

Closed dnbln closed 3 years ago

dnbln commented 3 years ago

Relevant bits in lalrpop's sources: lalrpop/src/build/action.rs#L66-L73

grammar.prefix created here: lalrpop/src/parser/lrgrammar.lalrpop#L31

And adjusted here(by adding "_" to the prefix till it doesn't appear in input; don't know why but we can just use ::lalrpop_util::...): lalrpop/src/parser/mod.rs#L49-L52

Code to determine location, token and error types: lalrpop/src/normalize/tyinfer/mod.rs#L66-L145