Index: pkg/compiler/lib/src/js_backend/codegen/task.dart |
diff --git a/pkg/compiler/lib/src/js_backend/codegen/task.dart b/pkg/compiler/lib/src/js_backend/codegen/task.dart |
index cf21b0b3b925bcead12f35d4d97832f02606962d..c293d5abe17b15d406139f44d4ed3d62c4e7e3be 100644 |
--- a/pkg/compiler/lib/src/js_backend/codegen/task.dart |
+++ b/pkg/compiler/lib/src/js_backend/codegen/task.dart |
@@ -336,7 +336,7 @@ class CpsFunctionCompiler implements FunctionCompiler { |
code = backend.rewriteAsync(element, code); |
work.registry.registerAsyncMarker(element); |
} |
- return attachPosition(code, element); |
+ return attachPosition(code, work.resolvedAst); |
} |
Iterable<CompilerTask> get tasks { |
@@ -348,9 +348,9 @@ class CpsFunctionCompiler implements FunctionCompiler { |
]..addAll(fallbackCompiler.tasks); |
} |
- js.Node attachPosition(js.Node node, AstElement element) { |
+ js.Node attachPosition(js.Node node, ResolvedAst resolvedAst) { |
return node.withSourceInformation(sourceInformationFactory |
- .createBuilderForContext(element) |
- .buildDeclaration(backend.frontend.getResolvedAst(element))); |
+ .createBuilderForContext(resolvedAst) |
+ .buildDeclaration(resolvedAst)); |
} |
} |