Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show source line and pointer to the invalid token in error message #19

Closed
DmitrySoshnikov opened this issue Jan 17, 2017 · 0 comments
Closed

Comments

@DmitrySoshnikov
Copy link
Owner

DmitrySoshnikov commented Jan 17, 2017

When we get "Unexpected token" error from the tokenizer or parser, we currently just show:

Unexpected token: "..." at <line>:<column>

In addition it'd be good to show an actual line from the original source, and a pointer to the invalid token:

foo + &7;
      ^ 
Unexpected token: "&" at <line>:<column>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant