blob: 98b7bf81680518f26766a2f4ff71057b6bf78600 [file] [log] [blame]
// Arrow functions can have primitive |this| values.
Number.prototype.foo = function() {
"use strict";
return () => this;
}
for (var i=0; i<5; i++) {
var n = i.foo()();
assertEq(typeof n, "number");
assertEq(n, i);
}