swc/crates/swc_ecma_parser/tests/tsc/iteratorSpreadInArray9.ts

14 lines
206 B
TypeScript

//@target: ES6
class SymbolIterator {
next() {
return {
value: Symbol()
};
}
[Symbol.iterator]() {
return this;
}
}
var array = [...new SymbolIterator];