Chromium Code Reviews| Index: lib/compiler/implementation/dart_backend/placeholder_collector.dart |
| diff --git a/lib/compiler/implementation/dart_backend/placeholder_collector.dart b/lib/compiler/implementation/dart_backend/placeholder_collector.dart |
| index e4813c71903645dea9d6e8e612ea50e4205624be..87065c14a8d24c32809ce91d5d3cf1d5f009a26d 100644 |
| --- a/lib/compiler/implementation/dart_backend/placeholder_collector.dart |
| +++ b/lib/compiler/implementation/dart_backend/placeholder_collector.dart |
| @@ -98,6 +98,9 @@ class PlaceholderCollector extends AbstractVisitor { |
| Element currentElement; |
| TreeElements treeElements; |
| + LibraryElement get coreLibrary => compiler.coreLibrary; |
| + FunctionElement get entryFunction => compiler.mainApp.find(Compiler.MAIN); |
| + |
| PlaceholderCollector(this.compiler) : |
| nullNodes = new Set<Node>(), |
| unresolvedNodes = new Set<Identifier>(), |
| @@ -257,6 +260,8 @@ class PlaceholderCollector extends AbstractVisitor { |
| void makeElementPlaceholder(Node node, Element element) { |
| assert(element !== null); |
| + if (element === entryFunction) return; |
|
Roman
2012/08/21 07:44:58
This is not the problem of your CL, but we should
Anton Muhin
2012/08/21 09:16:54
Good point, I'll fix it.
On 2012/08/21 07:44:58,
|
| + if (element.getLibrary() === coreLibrary) return; |
| elementNodes.putIfAbsent(element, () => new Set<Node>()).add(node); |
| } |