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

Side by Side Diff: pkg/kernel/testcases/interpreter/try_catch_finally_test.dart

Issue 2985383002: Add partial support for TryFinally and TryCatch statements (Closed)
Patch Set: Merge 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
(Empty)
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
3 // BSD-style license that can be found in the LICENSE file.
4
5 main() {
6 try {
7 print('hello1');
8 } catch (e, _) {} finally {
9 print('hello2');
10 }
11 print('hello3');
12 print(foo());
13 print(bar());
14 }
15
16 int foo() {
17 try {
18 print('foo 1');
19 return 1;
20 } catch (e, _) {} finally {
21 print('foo 2');
22 return 2;
23 }
24 }
25
26 int bar() {
27 try {
28 print('bar 1');
29 return 1;
30 } catch (e, _) {} finally {
31 print('bar 2');
32 }
33 return 0;
34 }
OLDNEW
« no previous file with comments | « pkg/kernel/lib/interpreter/interpreter.dart ('k') | pkg/kernel/testcases/interpreter/try_catch_finally_test.dart.expect » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698