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

Side by Side Diff: test/mjsunit/regress/regress-5106.js

Issue 2110193002: Do all parsing for try/catch destructuring inside the appropriate scopes (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: One less scope Created 4 years, 5 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 function* g1() {
6 try {
7 throw {};
8 } catch ({a = class extends (yield) {}}) {
9 }
10 }
11 g1().next(); // crashes without fix
12
13 function* g2() {
14 let x = function(){};
15 try {
16 throw {};
17 } catch ({b = class extends x {}}) {
18 }
19 }
20 g2().next(); // crashes without fix
21
22 function* g3() {
23 let x = 42;
24 try {
25 throw {};
26 } catch ({c = (function() { return x })()}) {
27 }
28 }
29 g3().next(); // throws a ReferenceError without fix
OLDNEW
« src/parsing/parser.cc ('K') | « src/parsing/parser.cc ('k') | test/test262/test262.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698