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

Unified Diff: test/mjsunit/regress/regress-4970.js

Issue 1931003003: Fix 'eval' in class extends clauses to be always-strict (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Remove unrelated test case Created 4 years, 8 months 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
« no previous file with comments | « src/parsing/parser-base.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/regress/regress-4970.js
diff --git a/test/mjsunit/regress/regress-crbug-513471.js b/test/mjsunit/regress/regress-4970.js
similarity index 60%
copy from test/mjsunit/regress/regress-crbug-513471.js
copy to test/mjsunit/regress/regress-4970.js
index 48c793e512315284ddf218f8847d9c357280fe95..da0033b34f57891945eea6f97ee8c760956dcd36 100644
--- a/test/mjsunit/regress/regress-crbug-513471.js
+++ b/test/mjsunit/regress/regress-4970.js
@@ -1,10 +1,15 @@
// Copyright 2016 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-
+//
// Flags: --allow-natives-syntax
-var g = (function*(){});
-var f = g();
+function g() {
+ var f;
+ class C extends eval("f = () => delete C; Array") {}
+ f();
+}
+
+assertThrows(g, SyntaxError);
%OptimizeFunctionOnNextCall(g);
-f.next();
+assertThrows(g, SyntaxError);
« no previous file with comments | « src/parsing/parser-base.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698