-
-
Notifications
You must be signed in to change notification settings - Fork 142
Fix function declarations with ms_call_modifier being incorrect. #321
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
Conversation
|
@maxbrunsfeld @amaanq @jdrouhard @Tomcat-42 Could one of you look into this review? It's a very small pull request, and no tests fail. It's currently blocking me from my work. Thanks. |
|
You need to commit all the artifacts from the generate command, not just parser.c. |
|
Just to clarify, what am I missing to get this to work? |
|
Probably need to use the tree-sitter binary that would be in |
I have been doing it via NPM this whole time with this: as per advice on the Tree Sitter discord. Is there another way I'm supposed to be doing it? |
|
The consensus seems to be from the tree-sitter Discord that the CI is actually what's wrong here, because this repo is using ABI 14 instead of ABI 15. Is that correct? |
|
Sorry @eezstreet ... when it comes to changes the upstream tree-sitter versions make to generated files, I'm not going to be much help. From what I can tell, the ci job always uses the latest tree-sitter CLI to generate the parser.c from grammar.js and then does a diff against what's actually in the repo. The local npm version of tree-sitter is behind a couple versions now, so even when we tell ci (which uses the newer tree-sitter CLI) to generate with an ABI of 14, the files still don't match 100%. It looks like we just need to upgrade the repo's tree-sitter version (and maybe jump to ABI 15 while we're at it) and regenerate before attempting to change the grammar. @amaanq - can you help us take care of this the right way? |
0ef20b0 to
d33b6a6
Compare
|
I merged another PR that gets our CI green, so I rebased your branch on top of that and regenerated the grammar. |
Previously, function declarations which had an
ms_call_modifierwere not being parsed correctly.This brings the grammar in-line with the C grammar, which parses it correctly.
In the C grammar, this example line of code will parse correctly, but in the current C++ parser, will not parse correctly, which this pull request addresses: