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

Should not parse invalid code import from 'foo' #258

Closed
fisker opened this issue Jun 5, 2024 · 6 comments · Fixed by #259
Closed

Should not parse invalid code import from 'foo' #258

fisker opened this issue Jun 5, 2024 · 6 comments · Fixed by #259
Assignees

Comments

@fisker
Copy link
Collaborator

fisker commented Jun 5, 2024

import from 'foo'

should be invalid code.

@3cp
Copy link
Member

3cp commented Jun 5, 2024

Interesting how did we miss that :)

@3cp 3cp self-assigned this Jun 5, 2024
@3cp
Copy link
Member

3cp commented Jun 5, 2024

It parsed "from" as the ImportDefaultSpecifier. Way off.

@3cp
Copy link
Member

3cp commented Jun 5, 2024

Side note: import from from 'foo' is valid code...

@3cp
Copy link
Member

3cp commented Jun 5, 2024

A missed check, quite simple to fix.
Also found out import {} from 'foo' is valid...

@fisker
Copy link
Collaborator Author

fisker commented Jun 5, 2024

Also found out import {} from 'foo' is valid...

Yes, equals to import 'foo'

@3cp 3cp closed this as completed in #259 Jun 5, 2024
@3cp
Copy link
Member

3cp commented Jun 6, 2024

v4.4.4 is released.

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 a pull request may close this issue.

2 participants