-
Notifications
You must be signed in to change notification settings - Fork 25.3k
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(compiler-cli): track visited source files in PartialEvaluator #29539
Conversation
7cd4aea
to
fa24d13
Compare
@@ -231,6 +233,9 @@ export class StaticInterpreter { | |||
} | |||
|
|||
private visitDeclaration(node: ts.Declaration, context: Context): ResolvedValue { | |||
if (this.visitedFilesCb) { | |||
this.visitedFilesCb(node.getSourceFile()); |
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.
Well, that was easier than I expected.
I suppose this catches everything. We add the starting expression, plus the ts.SourceFile
of any declaration we traverse while evaluating... I think that'll work.
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.
I couldn't think of any other scenarios (except for the annoying re-re-export situation) that we would miss.
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
// FW-1194