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

Unified Diff: pkg/compiler/lib/src/resolution/resolution_strategy.dart

Issue 2980953002: Use entities in most of MirrorsData (part 2) (Closed)
Patch Set: Updated cf. comment Created 3 years, 5 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/js_backend/mirrors_data.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/resolution/resolution_strategy.dart
diff --git a/pkg/compiler/lib/src/resolution/resolution_strategy.dart b/pkg/compiler/lib/src/resolution/resolution_strategy.dart
index 00c66e2c89c5e0bfac29b49c1f42653cf2b79106..1672fc5ef6b9508a744b1aef8b0257020056bd9b 100644
--- a/pkg/compiler/lib/src/resolution/resolution_strategy.dart
+++ b/pkg/compiler/lib/src/resolution/resolution_strategy.dart
@@ -34,6 +34,7 @@ import '../js_backend/runtime_types.dart';
import '../library_loader.dart';
import '../native/enqueue.dart' show NativeResolutionEnqueuer;
import '../native/resolver.dart';
+import '../options.dart';
import '../tree/tree.dart' show Node;
import '../serialization/task.dart';
import '../patch_parser.dart';
@@ -108,7 +109,7 @@ class ResolutionFrontEndStrategy extends FrontendStrategyBase
new ResolutionNoSuchMethodResolver();
MirrorsDataBuilder createMirrorsDataBuilder() {
- return new MirrorsDataImpl(
+ return new ResolutionMirrorsData(
_compiler, _compiler.options, elementEnvironment, commonElements);
}
@@ -936,3 +937,24 @@ class ResolutionWorkItemBuilder extends WorkItemBuilder {
return _resolution.createWorkItem(element);
}
}
+
+class ResolutionMirrorsData extends MirrorsDataImpl {
+ ResolutionMirrorsData(Compiler compiler, CompilerOptions options,
+ ElementEnvironment elementEnvironment, CommonElements commonElements)
+ : super(compiler, options, elementEnvironment, commonElements);
+
+ @override
+ bool isClassInjected(covariant ClassElement cls) => cls.isInjected;
+
+ @override
+ bool isClassResolved(covariant ClassElement cls) => cls.isResolved;
+
+ @override
+ void forEachConstructor(
+ covariant ClassElement cls, void f(ConstructorEntity constructor)) {
+ cls.constructors.forEach((Element _constructor) {
+ ConstructorElement constructor = _constructor;
+ f(constructor);
+ });
+ }
+}
« no previous file with comments | « pkg/compiler/lib/src/js_backend/mirrors_data.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698