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

Unified Diff: pkg/compiler/lib/src/enqueue.dart

Issue 2563623002: Merge _applyMemberUse and _applyStaticMemberUse in ResolutionEnqueuer (Closed)
Patch Set: Created 4 years 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 | « no previous file | pkg/compiler/lib/src/universe/world_builder.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/enqueue.dart
diff --git a/pkg/compiler/lib/src/enqueue.dart b/pkg/compiler/lib/src/enqueue.dart
index cb41939454f8b2e2fd07ef7439b1504ac7b7f426..e5ae7cb6f9ed7e2b2b849eeccac5e727ddbb8483 100644
--- a/pkg/compiler/lib/src/enqueue.dart
+++ b/pkg/compiler/lib/src/enqueue.dart
@@ -224,9 +224,12 @@ class ResolutionEnqueuer extends EnqueuerImpl {
if (useSet.contains(MemberUse.NORMAL)) {
_addToWorkList(member);
}
- if (useSet.contains(MemberUse.CLOSURIZE)) {
+ if (useSet.contains(MemberUse.CLOSURIZE_INSTANCE)) {
_registerClosurizedMember(member);
}
+ if (useSet.contains(MemberUse.CLOSURIZE_STATIC)) {
+ applyImpact(backend.registerGetOfStaticFunction());
+ }
}
/// Callback for applying the use of a [cls].
@@ -250,18 +253,8 @@ class ResolutionEnqueuer extends EnqueuerImpl {
});
}
- /// Callback for applying the use of a [member].
- void _applyStaticMemberUse(Entity member, EnumSet<MemberUse> useSet) {
- if (useSet.contains(MemberUse.NORMAL)) {
- _addToWorkList(member);
- }
- if (useSet.contains(MemberUse.CLOSURIZE)) {
- applyImpact(backend.registerGetOfStaticFunction());
- }
- }
-
void processStaticUse(StaticUse staticUse) {
- _universe.registerStaticUse(staticUse, _applyStaticMemberUse);
+ _universe.registerStaticUse(staticUse, _applyMemberUse);
// TODO(johnniwinther): Add `ResolutionWorldBuilder.registerConstructorUse`
// for these:
switch (staticUse.kind) {
« no previous file with comments | « no previous file | pkg/compiler/lib/src/universe/world_builder.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698