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

[Bug]: Wrong evaluation order when using spread in function argument #14999

Open
1 task
p51lee opened this issue Sep 30, 2022 · 1 comment
Open
1 task

[Bug]: Wrong evaluation order when using spread in function argument #14999

p51lee opened this issue Sep 30, 2022 · 1 comment

Comments

@p51lee
Copy link

p51lee commented Sep 30, 2022

💻

  • Would you like to work on a fix?

How are you using Babel?

Other (Next.js, Gatsby, vue-cli, ...)

Input code

null ( 0 , ... x ) ;

Configuration file name

No response

Configuration

No response

Current and expected behavior

ReferenceError is expected (in step 3) in the input program but the transpiled program throws TypeError (in step 5).

Image

node
Welcome to Node.js v18.10.0.
Type ".help" for more information.
> null ( 0 , ... x ) ;
Uncaught ReferenceError: x is not defined

Environment

Reproductions on Babel's own REPL

Possible solution

No response

Additional context

No response

@babel-bot
Copy link
Collaborator

Hey @p51lee! We really appreciate you taking the time to report an issue. The collaborators on this project attempt to help as many people as possible, but we're a limited number of volunteers, so it's possible this won't be addressed swiftly.

If you need any help, or just have general Babel or JavaScript questions, we have a vibrant Slack community that typically always has someone willing to help. You can sign-up here for an invite.

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

No branches or pull requests

4 participants