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

1-24 minilint can't handle the case "({)}" #2

Open
tcztzy opened this issue Dec 23, 2016 · 1 comment
Open

1-24 minilint can't handle the case "({)}" #2

tcztzy opened this issue Dec 23, 2016 · 1 comment

Comments

@tcztzy
Copy link

tcztzy commented Dec 23, 2016

The case "({)}" cause syntax error, but your program cannot handle this correctly.

@ptdecker
Copy link
Owner

ptdecker commented Dec 29, 2016

Correct, the solution does not utilize any syntactic analysis. The problem was solved in a way consistent with a chapter one overview lesson for the book. A proper linter would need to be able to parse the language at hand with proper lexical analysis. I would certainly welcome an "extras" pull request which does this. Also, a compromise could be written that simply checks for odd numbered counters when a closing symbol is encountered which would indicate improper nesting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants