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

Unified Diff: tests/language/for_test.dart

Issue 459763003: dart2dart: Fix a scoping bug in the translation of loops. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
Index: tests/language/for_test.dart
diff --git a/tests/language/for_test.dart b/tests/language/for_test.dart
index 96773998d0144803d76576db0cca8ceb1a579759..a461f5146716188d84bc3f2849dd143cac6787aa 100644
--- a/tests/language/for_test.dart
+++ b/tests/language/for_test.dart
@@ -45,6 +45,12 @@ class Helper {
}
status = 1;
}
+
+ static int f6() {
sigurdm 2014/08/12 07:26:37 Maybe a comment explaining what we are testing?
Kevin Millikin (Google) 2014/08/12 08:54:55 Good idea, done.
+ int i = 0;
+ for (; ++i < 3; ) {}
+ return i;
+ }
}
class ForTest {
@@ -67,6 +73,8 @@ class ForTest {
Helper.f5();
Expect.equals(1, Helper.status);
+
+ Expect.equals(3, Helper.f6());
}
}

Powered by Google App Engine
This is Rietveld 408576698