Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1651)

Unified Diff: test/mjsunit/es6/classes.js

Issue 2430383004: Remove the 'caller' property from the strict-mode arguments map (Closed)
Patch Set: Remove the 'caller' property from the strict-mode arguments map Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: test/mjsunit/es6/classes.js
diff --git a/test/mjsunit/es6/classes.js b/test/mjsunit/es6/classes.js
index fb77dbb8e4b01bb273512b215763dadbb1077661..816d113263a9af9c150ea582d96fceeb3130f54e 100644
--- a/test/mjsunit/es6/classes.js
+++ b/test/mjsunit/es6/classes.js
@@ -164,14 +164,15 @@
SyntaxError);
var D = class extends function() {
- arguments.caller;
+ this.args = arguments;
} {};
assertThrows(function() {
Object.getPrototypeOf(D).arguments;
}, TypeError);
- assertThrows(function() {
- new D;
- }, TypeError);
+ var e = new D();
+ assertThrows(() => e.args.callee, TypeError);
+ assertEquals(undefined, Object.getOwnPropertyDescriptor(e.args, 'caller'));
+ assertFalse('caller' in e.args);
})();

Powered by Google App Engine
This is Rietveld 408576698