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

fix: disallow empty groupings #44

Merged
merged 1 commit into from
Nov 9, 2024

Conversation

ribru17
Copy link
Contributor

@ribru17 ribru17 commented Oct 25, 2024

Something like () is a syntax error and it would be nice if the parser reflected that (even if just with a "missing" node rather than an error node).

ts g ran with 0.24.3

@clason
Copy link
Contributor

clason commented Oct 25, 2024

ts g ran with 0.24.3

Then you need to git add the new tree-sitter.json.

@ObserverOfTime
Copy link
Member

See #42

@ribru17
Copy link
Contributor Author

ribru17 commented Oct 25, 2024

Yeah I'll just wait for that one to merge then rebase

@ribru17 ribru17 force-pushed the no_empty_groupings branch from 0f6f3c6 to 63e0cb9 Compare November 7, 2024 02:10
Something like `()` or `[]` is a syntax error and it would be nice if
the parser reflected that (even if just with a "missing" node rather
than an error node).
@ribru17 ribru17 force-pushed the no_empty_groupings branch from 63e0cb9 to 3b59901 Compare November 9, 2024 23:39
@amaanq amaanq merged commit d0d9126 into tree-sitter-grammars:master Nov 9, 2024
3 checks passed
@clason
Copy link
Contributor

clason commented Nov 10, 2024

Something like () is a syntax error and it would be nice if the parser reflected that

For the record, that goes against the general policy that tree-sitter parsers should not try to be linters. (And the breakage in nvim-treesitter shows why...)

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 this pull request may close these issues.

4 participants