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

Unified Diff: pkg/kernel/testcases/closures/closure_in_initializer_closure.dart.expect

Issue 2767773004: Add Vector type to Kernel (Closed)
Patch Set: Reformat comment with Markdown, throw exception in type propagation 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: pkg/kernel/testcases/closures/closure_in_initializer_closure.dart.expect
diff --git a/pkg/kernel/testcases/closures/closure_in_initializer_closure.dart.expect b/pkg/kernel/testcases/closures/closure_in_initializer_closure.dart.expect
index f0832d75266644b660b274783c73894e674f3834..8be11e913ce9fe7d4b941d6d69b9711ce0757fd8 100644
--- a/pkg/kernel/testcases/closures/closure_in_initializer_closure.dart.expect
+++ b/pkg/kernel/testcases/closures/closure_in_initializer_closure.dart.expect
@@ -1,55 +1,54 @@
library;
import self as self;
import "dart:core" as core;
-import "dart:mock" as mock;
class C extends core::Object {
field dynamic t;
constructor foo(dynamic f) → void
- : self::C::t = let final mock::Context #context = new mock::Context::•(1) in let dynamic #t1 = #context.[]=(0, f) in new self::Closure#C#foo#function::•(#context), super core::Object::•() {
- final mock::Context #context = new mock::Context::•(1);
- #context.[]=(0, f);
+ : self::C::t = let final Vector #context = MakeVector(2) in let dynamic #t1 = #context[1] = f in new self::Closure#C#foo#function::•(#context), super core::Object::•() {
+ final Vector #context = MakeVector(2);
+ #context[1] = f;
core::print(1);
}
}
class Closure#C#foo#function#function extends core::Object implements core::Function {
field core::String note = "This is temporary. The VM doesn't need closure classes.";
- field mock::Context context;
- constructor •(final mock::Context context) → dynamic
+ field Vector context;
+ constructor •(final Vector context) → dynamic
: self::Closure#C#foo#function#function::context = context
;
method call(dynamic x) → dynamic {
"This is a temporary solution. In the VM, this will become an additional parameter.";
- final mock::Context #contextParameter = this.{self::Closure#C#foo#function#function::context};
- #contextParameter.parent.[](0).call("${#contextParameter.[](0)}${x}");
+ final Vector #contextParameter = this.{self::Closure#C#foo#function#function::context};
+ (#contextParameter[0][1]).call("${#contextParameter[1]}${x}");
}
}
class Closure#C#foo#function extends core::Object implements core::Function {
field core::String note = "This is temporary. The VM doesn't need closure classes.";
- field mock::Context context;
- constructor •(final mock::Context context) → dynamic
+ field Vector context;
+ constructor •(final Vector context) → dynamic
: self::Closure#C#foo#function::context = context
;
method call() → dynamic {
"This is a temporary solution. In the VM, this will become an additional parameter.";
- final mock::Context #contextParameter = this.{self::Closure#C#foo#function::context};
- final mock::Context #context = new mock::Context::•(1);
- #context.parent = #contextParameter;
- #context.[]=(0, null);
+ final Vector #contextParameter = this.{self::Closure#C#foo#function::context};
+ final Vector #context = MakeVector(2);
+ #context[0] = #contextParameter;
+ #context[1] = null;
dynamic g = new self::Closure#C#foo#function#function::•(#context);
- #context.[]=(0, "hest");
+ #context[1] = "hest";
return g;
}
}
class Closure#main#function extends core::Object implements core::Function {
field core::String note = "This is temporary. The VM doesn't need closure classes.";
- field mock::Context context;
- constructor •(final mock::Context context) → dynamic
+ field Vector context;
+ constructor •(final Vector context) → dynamic
: self::Closure#main#function::context = context
;
method call(dynamic x) → dynamic {
"This is a temporary solution. In the VM, this will become an additional parameter.";
- final mock::Context #contextParameter = this.{self::Closure#main#function::context};
+ final Vector #contextParameter = this.{self::Closure#main#function::context};
return core::print(x);
}
}
« no previous file with comments | « pkg/kernel/testcases/closures/closure_in_initializer.dart.expect ('k') | pkg/kernel/testcases/closures/closures.dart.expect » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698