OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 library dart2js.enqueue; | 5 library dart2js.enqueue; |
6 | 6 |
7 import 'dart:collection' show Queue; | 7 import 'dart:collection' show Queue; |
8 | 8 |
9 import 'common/codegen.dart' show CodegenWorkItem; | 9 import 'common/codegen.dart' show CodegenWorkItem; |
10 import 'common/names.dart' show Identifiers; | 10 import 'common/names.dart' show Identifiers; |
(...skipping 698 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
709 bool isProcessed(Element member) => processedElements.contains(member); | 709 bool isProcessed(Element member) => processedElements.contains(member); |
710 | 710 |
711 /// Returns `true` if [element] has been processed by the resolution enqueuer. | 711 /// Returns `true` if [element] has been processed by the resolution enqueuer. |
712 bool hasBeenProcessed(Element element) { | 712 bool hasBeenProcessed(Element element) { |
713 return processedElements.contains(element.analyzableElement.declaration); | 713 return processedElements.contains(element.analyzableElement.declaration); |
714 } | 714 } |
715 | 715 |
716 /// Registers [element] as processed by the resolution enqueuer. | 716 /// Registers [element] as processed by the resolution enqueuer. |
717 void registerProcessedElement(AstElement element) { | 717 void registerProcessedElement(AstElement element) { |
718 processedElements.add(element); | 718 processedElements.add(element); |
| 719 compiler.backend.onElementResolved(element); |
719 } | 720 } |
720 | 721 |
721 /** | 722 /** |
722 * Decides whether an element should be included to satisfy requirements | 723 * Decides whether an element should be included to satisfy requirements |
723 * of the mirror system. | 724 * of the mirror system. |
724 * | 725 * |
725 * During resolution, we have to resort to matching elements against the | 726 * During resolution, we have to resort to matching elements against the |
726 * [MirrorsUsed] pattern, as we do not have a complete picture of the world, | 727 * [MirrorsUsed] pattern, as we do not have a complete picture of the world, |
727 * yet. | 728 * yet. |
728 */ | 729 */ |
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1016 } | 1017 } |
1017 | 1018 |
1018 typedef void _DeferredActionFunction(); | 1019 typedef void _DeferredActionFunction(); |
1019 | 1020 |
1020 class _DeferredAction { | 1021 class _DeferredAction { |
1021 final Element element; | 1022 final Element element; |
1022 final _DeferredActionFunction action; | 1023 final _DeferredActionFunction action; |
1023 | 1024 |
1024 _DeferredAction(this.element, this.action); | 1025 _DeferredAction(this.element, this.action); |
1025 } | 1026 } |
OLD | NEW |