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

Make processTaggedTemplateExpression visit a returned node #38596

Merged
merged 1 commit into from
May 15, 2020

Conversation

elibarzilay
Copy link
Contributor

This problem was introduced in 70399e1 (from PR #23801), which added
a visitTaggedTemplateExpression case for TaggedTemplateExpression,
before that, it would fallback to the default of visitNode. So re-add
that happen in processTaggedTemplateExpression.

Since it doesn't hurt, I left a Debug.checkDefined(property.name)
instead of !-ing it.

Fixes #38558.

Copy link
Contributor

@Kingwl Kingwl left a comment

Choose a reason for hiding this comment

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

Sorry, my bad.

This problem was introduced in 70399e1 (from PR microsoft#23801), which added
a `visitTaggedTemplateExpression` case for `TaggedTemplateExpression`,
before that, it would fallback to the default of `visitNode`.  So re-add
that happen in `processTaggedTemplateExpression`.

Since it doesn't hurt, I left a `Debug.checkDefined(property.name)`
instead of `!`-ing it.

Fixes microsoft#38558.
@eliasjnior
Copy link

I could run with yarn add [email protected] and the error stoped!

@dandrei
Copy link

dandrei commented May 21, 2020

@eliasjnior that's because the problem didn't exist in 3.8.3.
But the problem is still present in 3.9.3. See: vercel/next.js#12854

@elibarzilay
Copy link
Contributor Author

@dandrei: this is most likely a different problem -- #38383 (which I couldn't reproduce).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Visitor throws Cannot read property 'kind' of undefined using [email protected]
7 participants