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

Unified Diff: tests/compiler/dart2js_extra/switch_test.dart

Issue 2774783002: Re-land "Format all multitests" (Closed)
Patch Set: Created 3 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
Index: tests/compiler/dart2js_extra/switch_test.dart
diff --git a/tests/compiler/dart2js_extra/switch_test.dart b/tests/compiler/dart2js_extra/switch_test.dart
index 93bc2295c0df3b02754459bd6681e8e0d8b9eb26..7acade2f3fe8551c601dc191610cd3a9c108b811 100644
--- a/tests/compiler/dart2js_extra/switch_test.dart
+++ b/tests/compiler/dart2js_extra/switch_test.dart
@@ -7,23 +7,22 @@ import "package:expect/expect.dart";
switcher(val) {
var x = 0;
switch (val) {
- case 1:
- x = 100;
- break;
- case 2:
- x = 200;
- break;
- case 3:
- x = 300;
- break;
- default:
- return 400;
- break; // Intentional dead code (regression test for crash).
+ case 1:
+ x = 100;
+ break;
+ case 2:
+ x = 200;
+ break;
+ case 3:
+ x = 300;
+ break;
+ default:
+ return 400;
+ break; // Intentional dead code (regression test for crash).
}
return x;
}
-
// Check unambiguated grammar allowing multiple lables per case/default.
switcher2(val) {
var x = 0;
@@ -33,7 +32,8 @@ switcher2(val) {
case 1:
baz:
case 2:
- fez: {
+ fez:
+ {
x = 100;
break fez;
}
@@ -44,7 +44,8 @@ switcher2(val) {
case 4:
svin:
default:
- barber: {
+ barber:
+ {
if (val > 2) {
x = 200;
break;
@@ -57,7 +58,6 @@ switcher2(val) {
return x;
}
-
badswitches(val) {
// Test some badly formed switch bodies.
// 01 - a label/statement without a following case/default.
« no previous file with comments | « tests/compiler/dart2js_extra/mirrors_used_warning_test.dart ('k') | tests/corelib/big_integer_arith_vm_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698