-
-
Notifications
You must be signed in to change notification settings - Fork 722
perf(linter): support getting as_member_expression_kind() variants
#14642
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
perf(linter): support getting as_member_expression_kind() variants
#14642
Conversation
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
CodSpeed Performance ReportMerging #14642 will not alter performanceComparing Summary
Footnotes
|
35c0726 to
66dcfe2
Compare
44bc4df to
58e17ae
Compare
66dcfe2 to
a5c8354
Compare
a5c8354 to
1a6c6fa
Compare
Merge activity
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Support extraction of variants from node.kind().as_member_expression_kind(), enabling the linter codegen to handle these cases without diverging let statements and improving performance.
- Add extraction of multiple variants via extract_variants_from_as_call returning NodeTypeSet
- Parse crates/oxc_ast/src/ast_kind_impl.rs at runtime to compute member expression kinds
- Introduce helper self_astkind_variant_from_path and use find_impl_function to locate the impl fn
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
1a6c6fa to
eb833e6
Compare
…14642) Previously, we bailed out on `node.kind().as_member_expression_kind()` diverging `let` statements. Now, we can compute those member expression kinds as they should be relatively constant. +1-3% on the linter benchmarks, plus we just dropped sub-millisecond on the Radix UI benchmark! <img width="719" height="427" alt="Screenshot 2025-10-15 at 5 11 00 PM" src="https://github.com/user-attachments/assets/a15d4a28-ad79-447a-9025-69368474a40e" />
eb833e6 to
73f2cbb
Compare

Previously, we bailed out on
node.kind().as_member_expression_kind()divergingletstatements. Now, we can compute those member expression kinds as they should be relatively constant.+1-3% on the linter benchmarks, plus we just dropped sub-millisecond on the Radix UI benchmark!