Sign in
webkit
/
WebKit
/
be9b4e2157fc5a81e712f3ea4e4907d0c2890556
/
.
/
JSTests
/
es6
/
Function_is_subclassable_correct_prototype_chain.js
blob: caaee439d75d02c6d5e3ae0754ca6492f8f82210 [
file
] [
log
] [
blame
]
function
test
()
{
class
C extends
Function
{}
var
c
=
new
C
(
"return 'foo';"
);
return
c instanceof C
&&
c instanceof
Function
&&
Object
.
getPrototypeOf
(
C
)
===
Function
;
}
if
(!
test
())
throw
new
Error
(
"Test failed"
);