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

Clean up lexer #50

Closed
kevlarr opened this issue Jun 11, 2022 · 0 comments · Fixed by #51
Closed

Clean up lexer #50

kevlarr opened this issue Jun 11, 2022 · 0 comments · Fixed by #51

Comments

@kevlarr
Copy link
Collaborator

kevlarr commented Jun 11, 2022

Lexer currently makes too many decisions about valid syntax when it should just be collecting valid tokens. It shouldn't care that some@ thing isn't a valid fragment.

Additionally, if it allowed some@ thing then it would emit the same tokens as some @thing since it scrubs whitespace, so there should most likely be a Token::Whitespace to represent any contiguous span of spaces and/or tabs.

It probably shouldn't also add a Newline unless there is one.

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

Successfully merging a pull request may close this issue.

1 participant