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

Unified Diff: pkg/compiler/lib/src/js_emitter/runtime_type_generator.dart

Issue 1638863002: Revert "Optimize subclass/subtype queries" (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 years, 11 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_emitter/js_emitter.dart ('k') | pkg/compiler/lib/src/ssa/builder.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/js_emitter/runtime_type_generator.dart
diff --git a/pkg/compiler/lib/src/js_emitter/runtime_type_generator.dart b/pkg/compiler/lib/src/js_emitter/runtime_type_generator.dart
index 9c48f4d82a2186b94feffa6dd68e115bb35724fa..61c1b08c8c5b9148eb9566ed22fd80fe8f6fab50 100644
--- a/pkg/compiler/lib/src/js_emitter/runtime_type_generator.dart
+++ b/pkg/compiler/lib/src/js_emitter/runtime_type_generator.dart
@@ -35,7 +35,6 @@ class RuntimeTypeGenerator {
JavaScriptBackend get backend => compiler.backend;
TypeTestRegistry get typeTestRegistry => emitterTask.typeTestRegistry;
- CoreClasses get coreClasses => compiler.coreClasses;
Set<ClassElement> get checkedClasses =>
typeTestRegistry.checkedClasses;
@@ -182,7 +181,7 @@ class RuntimeTypeGenerator {
}
if (superclass != null &&
- superclass != coreClasses.objectClass &&
+ superclass != compiler.coreClasses.objectClass &&
!haveSameTypeVariables(cls, superclass)) {
// We cannot inherit the generated substitutions, because the type
// variable layout for this class is different. Instead we generate
@@ -218,7 +217,7 @@ class RuntimeTypeGenerator {
// A class that defines a `call` method implicitly implements
// [Function] and needs checks for all typedefs that are used in is-checks.
- if (checkedClasses.contains(coreClasses.functionClass) ||
+ if (checkedClasses.contains(compiler.coreClasses.functionClass) ||
checkedFunctionTypes.isNotEmpty) {
Element call = cls.lookupLocalMember(Identifiers.call);
if (call == null) {
@@ -229,8 +228,8 @@ class RuntimeTypeGenerator {
FunctionElement callFunction = call;
// A superclass might already implement the Function interface. In such
// a case, we can avoid emiting the is test here.
- if (!cls.superclass.implementsFunction(coreClasses)) {
- _generateInterfacesIsTests(coreClasses.functionClass,
+ if (!cls.superclass.implementsFunction(compiler)) {
+ _generateInterfacesIsTests(compiler.coreClasses.functionClass,
generateIsTest,
generateSubstitution,
generated);
« no previous file with comments | « pkg/compiler/lib/src/js_emitter/js_emitter.dart ('k') | pkg/compiler/lib/src/ssa/builder.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698