-
Notifications
You must be signed in to change notification settings - Fork 30.7k
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
module: only try to enrich CJS syntax errors #35691
Conversation
It is guaranteed that V8 throws a syntax error when `import` or `export` is used outside of ESM. Fixes: nodejs#35687
Review requested:
|
The output is not ideal, but that is not new:
|
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.
lgtm
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.
lgtm
This comment has been minimized.
This comment has been minimized.
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.
Nit: Commit message should start with a verb. Maybe this?
module: enrich only CJS syntax errors
Landed in 5b2c263...11f1ad9 |
It is guaranteed that V8 throws a syntax error when `import` or `export` is used outside of ESM. Fixes: #35687 PR-URL: #35691 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
It is guaranteed that V8 throws a syntax error when `import` or `export` is used outside of ESM. Fixes: #35687 PR-URL: #35691 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
It is guaranteed that V8 throws a syntax error when `import` or `export` is used outside of ESM. Fixes: #35687 PR-URL: #35691 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
It is guaranteed that V8 throws a syntax error when `import` or `export` is used outside of ESM. Fixes: #35687 PR-URL: #35691 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
It is guaranteed that V8 throws a syntax error when `import` or `export` is used outside of ESM. Fixes: #35687 PR-URL: #35691 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
It is guaranteed that V8 throws a syntax error when
import
orexport
is used outside of ESM.
Fixes: #35687
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes