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

Unified Diff: pkg/front_end/lib/src/fasta/builder/class_builder.dart

Issue 2862223002: Rewrite mixin application handling in Fasta. (Closed)
Patch Set: Created 3 years, 7 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
Index: pkg/front_end/lib/src/fasta/builder/class_builder.dart
diff --git a/pkg/front_end/lib/src/fasta/builder/class_builder.dart b/pkg/front_end/lib/src/fasta/builder/class_builder.dart
index a908ecbb03e4f7f286f762fe6a67b1d0ac3a5e02..33f0d176fc93ca2e4b4c220599303c288c9e3207 100644
--- a/pkg/front_end/lib/src/fasta/builder/class_builder.dart
+++ b/pkg/front_end/lib/src/fasta/builder/class_builder.dart
@@ -56,8 +56,14 @@ abstract class ClassBuilder<T extends TypeBuilder, R>
/// superclass.
bool get isMixinApplication => mixedInType != null;
+ bool get isNamedMixinApplication {
+ return isMixinApplication && super.isNamedMixinApplication;
+ }
+
T get mixedInType;
+ void set mixedInType(T mixin);
+
List<ConstructorReferenceBuilder> get constructorReferences => null;
LibraryBuilder get library {
@@ -138,8 +144,9 @@ abstract class ClassBuilder<T extends TypeBuilder, R>
builder = t.builder;
arguments = t.arguments ?? const [];
if (builder is ClassBuilder) {
- variables = builder.typeVariables;
- supertype = builder.supertype;
+ ClassBuilder cls = builder;
+ variables = cls.typeVariables;
+ supertype = cls.supertype;
}
}
@@ -155,7 +162,8 @@ abstract class ClassBuilder<T extends TypeBuilder, R>
}
supertype = t.supertype;
} else {
- internalError("Superclass not found.", fileUri, charOffset);
+ internalError("Superclass not found '${superclass.fullNameForErrors}'.",
+ fileUri, charOffset);
}
if (variables != null) {
Map<TypeVariableBuilder, TypeBuilder> directSubstitutionMap =

Powered by Google App Engine
This is Rietveld 408576698