Sign in
webkit
/
WebKit
/
2e2cb00ac8a118644a070f63a7b5ac6a2db0e0aa
/
.
/
JSTests
/
es6
/
destructuring_rest.js
blob: 8f70af74fe00ad408213d68bd53ed2dc6dc97934 [
file
] [
log
] [
blame
]
function
test
()
{
var
[
a
,
...
b
]
=
[
3
,
4
,
5
];
var
[
c
,
...
d
]
=
[
6
];
return
a
===
3
&&
b instanceof
Array
&&
(
b
+
""
)
===
"4,5"
&&
c
===
6
&&
d instanceof
Array
&&
d
.
length
===
0
;
}
if
(!
test
())
throw
new
Error
(
"Test failed"
);