-
-
Notifications
You must be signed in to change notification settings - Fork 760
chore(parser): increase size of SyntaxKindSet bitfield #7994
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
chore(parser): increase size of SyntaxKindSet bitfield #7994
Conversation
|
CodSpeed Performance ReportMerging #7994 will not alter performanceComparing Summary
Footnotes
|
WalkthroughThe SyntaxKindSet bitset was expanded from 4 to 5 limbs. The public struct signature, from_raw initialisation, internal bits array, and union method were updated accordingly to handle the additional limb. The from_raw documentation example was also updated to reflect the structural changes. Pre-merge checks and finishing touches✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@ryan-m-walker did you verify that this change actually allows you to add more nodes? |
|
@ematipico yeah, I have a working branch for the |
|
@ematipico this is the other related PR: #7997 |
Summary
I am currently working on issue #6725 to add support for the new CSS
iffeature and while doing so had to add new syntax kinds. In doing so though I realized that adding them will go over a current limit of how many syntax kinds are able to be supported by the parser. Currently there are about 507 existing CSS kinds and the limit is 512. I wanted to split this out as it's own PR though, separate from the feature work since this is a deeper change to the parser and think it deserves more scrutiny. This PR just adds another u128 to theSyntaxKindSetstruct array to increase the max syntax kinds to 640.Test Plan
Full test suite of the repo passes
Docs
n/a
AI Assistance Disclosure
Claude Code was used to help locate where in the codebase the change needed to happen while working on the CSS
iffeature. The issue was originally surfaced by this check failing though.