Sign in
cobalt
/
cobalt
/
71840339e1109efe930df5c60712d91cdcc962a8
/
.
/
src
/
third_party
/
mozjs-45
/
js
/
src
/
jit-test
/
tests
/
arrow-functions
/
construct-1.js
blob: 0871888e3da1761b5cf4bf08bd31bffa224984b0 [
file
] [
log
] [
blame
]
// Arrow functions are not constructors.
load
(
libdir
+
"asserts.js"
);
var
f
=
a
=>
{
this
.
a
=
a
;
};
assertThrowsInstanceOf
(()
=>
new
f
,
TypeError
);
assertThrowsInstanceOf
(()
=>
new
f
(
1
,
2
),
TypeError
);