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

fix(language-core): any in templates if first checked file was not root #4526

Merged
merged 2 commits into from
Jul 4, 2024

Conversation

daniluk4000
Copy link
Contributor

Resolves #4470.

image

When debugging I found that our first file is our internal node modules component.

But since canonicalRootFileNamesVersion was set, and this file wasn't root, globalTypesHolder was never set.

@daniluk4000
Copy link
Contributor Author

#4452 could potentially break something else tho, but this fixes this problem for our case.

@daniluk4000 daniluk4000 changed the title fix(#4470): Resolve potential any in templates if first checked file was not root fix(#4470): any in templates if first checked file was not root Jul 3, 2024
@daniluk4000 daniluk4000 changed the title fix(#4470): any in templates if first checked file was not root fix: any in templates if first checked file was not root Jul 3, 2024
@johnsoncodehk
Copy link
Member

The current test infrastructure makes it difficult to add test cases for this bug, but the change looks good to me, thanks for looking into it!

@johnsoncodehk johnsoncodehk changed the title fix: any in templates if first checked file was not root fix(language-core): any in templates if first checked file was not root Jul 4, 2024
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 this pull request may close these issues.

infer type in template unexpectedly after v2.0.19
2 participants