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

Unified Diff: test/mjsunit/harmony/regress/regress-3741.js

Issue 762393008: Fix the order of context binding/simulate insertion for BlockContexts. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Test Created 6 years 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/hydrogen.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/harmony/regress/regress-3741.js
diff --git a/test/mjsunit/harmony/regress/regress-3741.js b/test/mjsunit/harmony/regress/regress-3741.js
new file mode 100644
index 0000000000000000000000000000000000000000..8a9dd9e09c787f0e8cc752e947d3a1fdb8315ee5
--- /dev/null
+++ b/test/mjsunit/harmony/regress/regress-3741.js
@@ -0,0 +1,26 @@
+// 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 --allow-natives-syntax
+'use strict';
+function f24(deopt) {
+ let x = 1;
+ {
+ let x = 2;
+ {
+ let x = 3;
+ assertEquals(3, x);
+ }
+ deopt + 1;
+ assertEquals(2, x);
+ }
+ assertEquals(1, x);
+}
+
+
+for (var j = 0; j < 10; ++j) {
+ f24(12);
+}
+%OptimizeFunctionOnNextCall(f24);
+f24({});
« no previous file with comments | « src/hydrogen.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698