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

Issue for parsing the struct with __attribute__ in C speicifer #47

Closed
PitterL opened this issue Jul 7, 2020 · 2 comments · Fixed by #150
Closed

Issue for parsing the struct with __attribute__ in C speicifer #47

PitterL opened this issue Jul 7, 2020 · 2 comments · Fixed by #150

Comments

@PitterL
Copy link

PitterL commented Jul 7, 2020

When we parse the struct which has the name and typedef name, with "attribute" tag, the parser will truncate it before the "attribute" and recoginize the " attribute" is an function, then parse failed.

typedef struct mxt_object { u8 type; u16 start_address; u8 size_minus_one; u8 instances_minus_one; u8 num_report_ids; } __attribute__((packed)) mxt_object_t;

But if we removed the name and typedef name in speicifer, the parser may be working.

Thanks.

@issue-label-bot
Copy link

Issue-Label Bot is automatically applying the label bug to this issue, with a confidence of 0.79. Please mark this comment with 👍 or 👎 to give our bot feedback!

Links: app homepage, dashboard and code for this bot.

@dcreager
Copy link

dcreager commented Jul 7, 2020

This looks like an issue with the C grammar in particular, and not with the tree-sitter framework as a whole. (Possibly a dup of #45) I'm going to move this issue to the C grammar's repo so we can triage it there.

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.

2 participants