Status: Untriaged
Owner: ----
New issue 6098 by
brett.ju...@avant.com: SyntaxError: Invalid destructuring assignment target on valid code
https://bugs.chromium.org/p/v8/issues/detail?id=6098Version: 5.7.492.63
OS: macOS El Capitan
Architecture: x64
What steps will reproduce the problem?
1. Run script
2. Get Syntax Error
What is the expected output?
Not to get a Syntax Error
What do you see instead?
Syntax Error
(Minimal code reproduction)
A function like this:
```
const fn = (c) => {
let d = [1, 2],
e = null,
f = null;
0 < c.getIn(['a']) ? [e, f] = d : [e, f] = d, console.log(e, f);
};
```
has a syntax error, however
```
const fn = (c) => {
let d = [1, 2],
e = null,
f = null;
0 < c.getIn([]) ? [e, f] = d : [e, f] = d, console.log(e, f);
};
```
is fine.
Babel, safari, and firefox do not give a syntax error, but Chrome & Node do.
there's some more info here where I initially reported it:
https://github.com/babel/babili/issues/476Let me know if any more information is needed
--
You received this message because:
1. The project was configured to send all issue notifications to this address
You may adjust your notification preferences at:
https://bugs.chromium.org/hosting/settings