Skip to content

Fix getTypeFromJSDocValueReference #35360

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

Merged
merged 1 commit into from
Nov 27, 2019
Merged

Conversation

elibarzilay
Copy link
Contributor

When using {import('./b').FOO} which is defined as a string literal,
valueType doesn't have a symbol.

This was exposed in 8223c07.

Fixes #34869.

@RyanCavanaugh
Copy link
Member

@typescript-bot cherry-pick this to release-3.7

@typescript-bot
Copy link
Collaborator

Hey @RyanCavanaugh, I couldn't open a PR with the cherry-pick. (You can check the log here). You may need to squash and pick this PR into release-3.7 manually.

Copy link
Member

@sandersn sandersn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think is a good patch fix but we'll need to understand the problem better for a permanent fix.

When using `{import('./b').FOO}` which is defined as a string literal,
`valueType` doesn't have a `symbol`.  Leave it for the fallback value
for now.

This was exposed in 8223c07.

Fixes microsoft#34869.
@elibarzilay elibarzilay merged commit d6740cf into microsoft:master Nov 27, 2019
@elibarzilay elibarzilay deleted the 34869 branch November 27, 2019 23:53
@elibarzilay
Copy link
Contributor Author

@typescript-bot cherry-pick this to release-3.7

@typescript-bot
Copy link
Collaborator

Hey @elibarzilay, I couldn't open a PR with the cherry-pick. (You can check the log here). You may need to squash and pick this PR into release-3.7 manually.

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.

TypeError: Cannot read property 'valueDeclaration' of undefined
4 participants