-
-
Notifications
You must be signed in to change notification settings - Fork 485
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
refactor(semantic): should not add symbols of ClassExpression and FunctionExpression to the scope #4141
Conversation
Your org has enabled the Graphite merge queue for merging into mainAdd the label “merge” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix. You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link. |
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
e5721da
to
adfebfa
Compare
CodSpeed Performance ReportMerging #4141 will degrade performances by 3.12%Comparing Summary
Benchmarks breakdown
|
adfebfa
to
9920171
Compare
f676841
to
e88e957
Compare
a4e1a1a
to
357ad9f
Compare
357ad9f
to
cbb7bfd
Compare
f5a2d06
to
2634b62
Compare
cbb7bfd
to
520d1f1
Compare
2634b62
to
7fe477a
Compare
7fe477a
to
3f07793
Compare
TypeScript Behavior
Create a symbol for the
id
ofClassExpression
andFunctionExpression
but doesn't add to the scopeClassExpression
: https://github.com/microsoft/TypeScript/blob/d8086f14b6b97c0df34a0cc2f56d4b5926a0c299/src/compiler/binder.ts#L3598-L3605FunctionExpression
: https://github.com/microsoft/TypeScript/blob/d8086f14b6b97c0df34a0cc2f56d4b5926a0c299/src/compiler/binder.ts#L3714-L3726Different resolve logic is implemented specifically for these ASTs.
ClassExpression
: https://github.com/microsoft/TypeScript/blob/d8086f14b6b97c0df34a0cc2f56d4b5926a0c299/src/compiler/utilities.ts#L11310-L11316FunctionExpression
: https://github.com/microsoft/TypeScript/blob/d8086f14b6b97c0df34a0cc2f56d4b5926a0c299/src/compiler/utilities.ts#L11375-L11378