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

13 lines
206 B
TypeScript

const [...a,] = [];
const {...b,} = {};
let c, d;
([...c,] = []);
({...d,} = {});
// Allowed for non-rest elements
const [e,] = <any>[];
const {f,} = <any>{};
let g, h;
([g,] = <any>[]);
({h,} = <any>{});