marcaube/rusty_monkey

Attach line number, column number and filename to tokens

Opened this issue · 0 comments

To output more useful messages during the parsing stage, it'd be useful to have some meta-data attached to the tokens, such as the line number, column number and filename.

Check https://github.com/rust-analyzer/ungrammar/blob/42810d770e4cddec2a5fff658489fa72f3b28a7c/src/lexer.rs#L17-L27 for inspiration.