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

Unified Diff: pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart

Issue 2360673003: kernel->ssa: Implement for-loops and while-loops (Closed)
Patch Set: Created 4 years, 3 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
« no previous file with comments | « pkg/compiler/lib/src/ssa/jump_handler.dart ('k') | pkg/compiler/lib/src/ssa/loop_handler.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
diff --git a/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart b/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
index 5cabeb84cf1ff4ebc2c65b41c987096f67d47db9..83bb32c8f678f7c5ce2a05260e8f099c6de90d5a 100644
--- a/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
+++ b/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
@@ -53,7 +53,7 @@ class KernelAstAdapter {
}
Compiler get _compiler => _backend.compiler;
- TreeElements get _elements => _resolvedAst.elements;
+ TreeElements get elements => _resolvedAst.elements;
ConstantValue getConstantForSymbol(ir.SymbolLiteral node) {
ast.Node astNode = getNode(node);
@@ -128,12 +128,12 @@ class KernelAstAdapter {
TypeMask typeOfInvocation(ir.MethodInvocation invocation) {
return _compiler.globalInference.results
- .typeOfSend(getNode(invocation), _elements);
+ .typeOfSend(getNode(invocation), elements);
}
TypeMask typeOfGet(ir.PropertyGet getter) {
return _compiler.globalInference.results
- .typeOfSend(getNode(getter), _elements);
+ .typeOfSend(getNode(getter), elements);
}
TypeMask inferredTypeOf(ir.Member node) {
@@ -152,7 +152,7 @@ class KernelAstAdapter {
ConstantValue getConstantFor(ir.Node node) {
ConstantValue constantValue =
- _backend.constants.getConstantValueForNode(getNode(node), _elements);
+ _backend.constants.getConstantValueForNode(getNode(node), elements);
assert(invariant(getNode(node), constantValue != null,
message: 'No constant computed for $node'));
return constantValue;
@@ -168,6 +168,9 @@ class KernelAstAdapter {
return _backend.isInterceptedSelector(selector);
}
+ JumpTarget getTargetDefinition(ir.Node node) =>
+ elements.getTargetDefinition(getNode(node));
+
ir.Procedure get mapLiteralConstructor =>
kernel.functions[_backend.helpers.mapLiteralConstructor];
« no previous file with comments | « pkg/compiler/lib/src/ssa/jump_handler.dart ('k') | pkg/compiler/lib/src/ssa/loop_handler.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698