babel / babylon

PSA: moved into babel/babel as @babel/parser -->

Home Page:https://github.com/babel/babel/tree/master/packages/babel-parser

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Disallow binding patterns of arrays or objects in BindingRestProperty

gsathya opened this issue · comments

Input Code

let {...{}} = {};

Babylon/Babel Configuration

stage3-preset

Expected Behavior

SyntaxError: ... must be followed by an identifier in declaration contexts

Current Behavior

No error

Your Environment

repl

This was already fixed and the latest versions of 6.x and 7.x both work for me. Also the repl seems to work for me successfully.

Also the repl seems to work for me successfully.

Does the link I pasted work? It doesn't throw a syntax error for me.

Ohh I mixed something up, I thought you expected it to pass and got an error, but you said the opposite. :)

commented

Yeah it was already an error in 6.x and I remember at the meeting we decided to make it actually an error but it got "fixed" lol so need to revert in a sense

Can be closed, PR already merged in :)

commented

Closed by #670, thanks @Andarist!