Tan Li Hau 8027dca501 fix object rest in array pattern (#10275)
* fix object rest in array pattern

* update test fixtures

* early return

* use path.stop() at the right path
2019-09-10 15:18:45 +02:00

20 lines
345 B
JavaScript

// ForXStatement
for (const [{a, ...b}] of []) {}
for ([{a, ...b}] of []) {}
async function a() {
for await ([{a, ...b}] of []) {}
}
// skip
for ([{a}] in {}) {}
for ([{a}] of []) {}
async function a() {
for await ([{a}] of []) {}
}
for ([a, ...b] in {}) {}
for ([a, ...b] of []) {}
async function a() {
for await ([a, ...b] of []) {}
}