Sign in
webkit
/
WebKit
/
5018b83b58300de6a946efbfe8a7056c14da27e0
/
.
/
JSTests
/
es6
/
well-known_symbols_Symbol.species_Array.prototype.slice.js
blob: fe90717247775dfb8e90d05d86f2d5bf00d8a4da [
file
] [
log
] [
blame
]
function
test
()
{
var
obj
=
[];
obj
.
constructor
=
{};
obj
.
constructor
[
Symbol
.
species
]
=
function
()
{
return
{
foo
:
1
};
};
return
Array
.
prototype
.
slice
.
call
(
obj
,
0
).
foo
===
1
;
}
if
(!
test
())
throw
new
Error
(
"Test failed"
);