huff-language / huff-rs

A low-level assembly language for the Ethereum Virtual Machine built in blazing-fast pure rust.
https://huff.sh
Apache License 2.0
590 stars 79 forks source link

Indicate where a parsing error occurred #312

Closed Mouradif closed 6 months ago

Mouradif commented 7 months ago

Hi!

When a parsing error happens during compilation, the parser doesn't give any hint as to where the error was found. It just says what token was found and what kind of token was expected.

Ideally, it would be great to have the line number but if the parser would at least output where was the cursor when the parsing error happened, it would help debugging.