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

Unified Diff: pkg/front_end/testcases/implicit_scope_test.dart.direct.expect

Issue 2829223007: Introduce initial plumbing for type promotion in fasta. (Closed)
Patch Set: Add missing copyrights Created 3 years, 8 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: pkg/front_end/testcases/implicit_scope_test.dart.direct.expect
diff --git a/pkg/front_end/testcases/implicit_scope_test.dart.direct.expect b/pkg/front_end/testcases/implicit_scope_test.dart.direct.expect
new file mode 100644
index 0000000000000000000000000000000000000000..098143672296d360791f5619da87cdf66bfcbae3
--- /dev/null
+++ b/pkg/front_end/testcases/implicit_scope_test.dart.direct.expect
@@ -0,0 +1,47 @@
+library;
+import self as self;
+import "dart:core" as core;
+import "package:expect/expect.dart" as exp;
+
+class ImplicitScopeTest extends core::Object {
+ constructor •() → void
+ : super core::Object::•()
+ ;
+ static method alwaysTrue() → core::bool {
+ return 1.+(1).==(2);
+ }
+ static method testMain() → dynamic {
+ dynamic a = "foo";
+ dynamic b;
+ if(self::ImplicitScopeTest::alwaysTrue()) {
+ dynamic a = "bar";
+ }
+ else {
+ dynamic b = a;
+ }
+ exp::Expect::equals("foo", a);
+ exp::Expect::equals(null, b);
+ while (!self::ImplicitScopeTest::alwaysTrue()) {
+ dynamic a = "bar";
+ dynamic b = "baz";
+ }
+ exp::Expect::equals("foo", a);
+ exp::Expect::equals(null, b);
+ for (core::int i = 0; i.<(10); i = i.+(1)) {
+ dynamic a = "bar";
+ dynamic b = "baz";
+ }
+ exp::Expect::equals("foo", a);
+ exp::Expect::equals(null, b);
+ do {
+ dynamic a = "bar";
+ dynamic b = "baz";
+ }
+ while ("black".==("white"))
+ exp::Expect::equals("foo", a);
+ exp::Expect::equals(null, b);
+ }
+}
+static method main() → dynamic {
+ self::ImplicitScopeTest::testMain();
+}

Powered by Google App Engine
This is Rietveld 408576698