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

Side by Side Diff: tests/compiler/dart2js/closure/data/parameter_in_try.dart

Issue 2999003002: Add more tested features to closure_test (Closed)
Patch Set: Updated cf. comments. Created 3 years, 4 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
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 readInFinally(/*inTry*/ parameter) { 5 readParameterInFinally(/*inTry*/ parameter) {
6 try { 6 try {
7 if (parameter) { 7 if (parameter) {
8 throw ''; 8 throw '';
9 } 9 }
10 } finally {} 10 } finally {}
11 } 11 }
12 12
13 writeInFinally(/*inTry*/ parameter) { 13 writeParameterInFinally(/*inTry*/ parameter) {
14 try { 14 try {
15 parameter = 42; 15 parameter = 42;
16 throw ''; 16 throw '';
17 } finally {} 17 } finally {}
18 } 18 }
19 19
20 readLocalInFinally(/**/ parameter) {
21 var /*inTry*/ local = parameter;
22 try {
23 if (local) {
24 throw '';
25 }
26 } finally {}
27 }
28
29 writeLocalInFinally(/**/ parameter) {
30 // ignore: UNUSED_LOCAL_VARIABLE
31 var /*inTry*/ local = parameter;
32 try {
33 local = 42;
34 throw '';
35 } finally {}
36 }
37
20 main() { 38 main() {
21 readInFinally(null); 39 readParameterInFinally(null);
22 writeInFinally(null); 40 writeParameterInFinally(null);
41 readLocalInFinally(null);
42 writeLocalInFinally(null);
23 } 43 }
OLDNEW
« no previous file with comments | « tests/compiler/dart2js/closure/data/captured_variable.dart ('k') | tests/compiler/dart2js/equivalence/id_equivalence.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698