BNFC / bnfc

BNF Converter
http://bnfc.digitalgrammars.com/
586 stars 165 forks source link

position token vs --functor #395

Open ScottFreeCode opened 3 years ago

ScottFreeCode commented 3 years ago

The --functor CLI option adds position information to the generated AST. It seems to do so except for tokens.

The language position token makes tokens include position info.

Is there a reason to keep these separate? If so, when would I prefer the token's position info and when would I avoid it?