Sign in
webkit
/
WebKit
/
a5225bd53e7051313cde07d2ab1113a860ab09bd
/
.
/
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"
);