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

Unified Diff: pkg/compiler/lib/src/cps_ir/type_propagation.dart

Issue 1136843006: dart2js cps: Access to lazily initialized fields. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rebase Created 5 years, 7 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/compiler/lib/src/cps_ir/type_propagation.dart
diff --git a/pkg/compiler/lib/src/cps_ir/type_propagation.dart b/pkg/compiler/lib/src/cps_ir/type_propagation.dart
index c0cdcb134e2529cace6538acf902a6a724f1df64..28795ca3e39e49cc0c0370cf5a29379b14f7fa43 100644
--- a/pkg/compiler/lib/src/cps_ir/type_propagation.dart
+++ b/pkg/compiler/lib/src/cps_ir/type_propagation.dart
@@ -829,6 +829,23 @@ class _TypePropagationVisitor<T> implements Visitor {
}
}
+ void visitGetStatic(GetStatic node) {
+ setValue(node, nonConstant());
+ }
+
+ void visitSetStatic(SetStatic node) {
+ setReachable(node.body);
+ }
+
+ void visitGetLazyStatic(GetLazyStatic node) {
+ Continuation cont = node.continuation.definition;
+ setReachable(cont);
+
+ assert(cont.parameters.length == 1);
+ Parameter returnValue = cont.parameters[0];
+ setValue(returnValue, nonConstant());
+ }
+
// Conditions.
void visitIsTrue(IsTrue node) {
@@ -872,14 +889,6 @@ class _TypePropagationVisitor<T> implements Visitor {
setReachable(node.body);
}
- void visitGetStatic(GetStatic node) {
- setValue(node, nonConstant());
- }
-
- void visitSetStatic(SetStatic node) {
- setReachable(node.body);
- }
-
void visitCreateBox(CreateBox node) {
setValue(node, nonConstant());
}
« no previous file with comments | « pkg/compiler/lib/src/cps_ir/shrinking_reductions.dart ('k') | pkg/compiler/lib/src/js_backend/codegen/codegen.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698