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

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

Issue 1007783002: Remove --harmony-scoping flag. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: CR feedback Created 5 years, 9 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 | « test/mjsunit/mjsunit.status ('k') | test/mjsunit/strict-mode.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/regress/regress-2506.js
diff --git a/test/mjsunit/regress/regress-2506.js b/test/mjsunit/regress/regress-2506.js
deleted file mode 100644
index 0eb2770e592a894999a8062f5feff0c14e10135a..0000000000000000000000000000000000000000
--- a/test/mjsunit/regress/regress-2506.js
+++ /dev/null
@@ -1,78 +0,0 @@
-// Copyright 2014 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: --harmony-scoping
-
-'use strict';
-
-// Top-level code
-let s = 0;
-let f = [undefined, undefined, undefined]
-for (const x of [1,2,3]) {
- s += x;
- f[x-1] = function() { return x; }
-}
-assertEquals(6, s);
-assertEquals(1, f[0]());
-assertEquals(2, f[1]());
-assertEquals(3, f[2]());
-
-let x = 1;
-s = 0;
-for (const x of [x, x+1, x+2]) {
- s += x;
-}
-assertEquals(6, s);
-
-s = 0;
-var q = 1;
-for (const q of [q, q+1, q+2]) {
- s += q;
-}
-assertEquals(6, s);
-
-let z = 1;
-s = 0;
-for (const x = 1; z < 2; z++) {
- s += x + z;
-}
-assertEquals(2, s);
-
-
-s = "";
-for (const x in [1,2,3]) {
- s += x;
-}
-assertEquals("012", s);
-
-assertThrows("'use strict'; for (const x in [1,2,3]) { x++ }", TypeError);
-
-// Function scope
-(function() {
- let s = 0;
- for (const x of [1,2,3]) {
- s += x;
- }
- assertEquals(6, s);
-
- let x = 1;
- s = 0;
- for (const x of [x, x+1, x+2]) {
- s += x;
- }
- assertEquals(6, s);
-
- s = 0;
- var q = 1;
- for (const q of [q, q+1, q+2]) {
- s += q;
- }
- assertEquals(6, s);
-
- s = "";
- for (const x in [1,2,3]) {
- s += x;
- }
- assertEquals("012", s);
-}());
« no previous file with comments | « test/mjsunit/mjsunit.status ('k') | test/mjsunit/strict-mode.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698