mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
22 lines
1.1 KiB
Plaintext
22 lines
1.1 KiB
Plaintext
declarationEmitDestructuringArrayPattern2.ts(4,6): error TS2493: Tuple type '[]' of length '0' has no element at index '0'.
|
|
declarationEmitDestructuringArrayPattern2.ts(4,11): error TS2493: Tuple type '[]' of length '0' has no element at index '1'.
|
|
declarationEmitDestructuringArrayPattern2.ts(4,16): error TS2493: Tuple type '[]' of length '0' has no element at index '2'.
|
|
|
|
|
|
==== declarationEmitDestructuringArrayPattern2.ts (3 errors) ====
|
|
var [x10, [y10, [z10]]] = [1, ["hello", [true]]];
|
|
|
|
var [x11 = 0, y11 = ""] = [1, "hello"];
|
|
var [a11, b11, c11] = [];
|
|
~~~
|
|
!!! error TS2493: Tuple type '[]' of length '0' has no element at index '0'.
|
|
~~~
|
|
!!! error TS2493: Tuple type '[]' of length '0' has no element at index '1'.
|
|
~~~
|
|
!!! error TS2493: Tuple type '[]' of length '0' has no element at index '2'.
|
|
|
|
var [a2, [b2, { x12, y12: c2 }]=["abc", { x12: 10, y12: false }]] = [1, ["hello", { x12: 5, y12: true }]];
|
|
|
|
var [x13, y13] = [1, "hello"];
|
|
var [a3, b3] = [[x13, y13], { x: x13, y: y13 }];
|
|
|