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

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

Issue 1881013002: Expand ResolvedAst to handle synthetic constructors. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Updated cf. comments + fix test, cps and compilation units for injected members. Created 4 years, 8 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/compiler/lib/src/resolution/resolution.dart
diff --git a/pkg/compiler/lib/src/resolution/resolution.dart b/pkg/compiler/lib/src/resolution/resolution.dart
index 7caced4336d7fe673b798a00271febf588d65621..92c49b937cd42d11dbbbbaf3d6b4c653680848e9 100644
--- a/pkg/compiler/lib/src/resolution/resolution.dart
+++ b/pkg/compiler/lib/src/resolution/resolution.dart
@@ -726,18 +726,19 @@ class ResolverTask extends CompilerTask {
// TODO(johnniwinther): Obtain the [TreeElements] for [member]
// differently.
if (compiler.enqueuer.resolution.hasBeenProcessed(member)) {
- checkMixinSuperUses(
- member.resolvedAst.elements, mixinApplication, mixin);
+ if (member.resolvedAst.kind == ResolvedAstKind.PARSED) {
+ checkMixinSuperUses(
+ member.resolvedAst.elements, mixinApplication, mixin);
+ }
}
}
});
}
- void checkMixinSuperUses(TreeElements resolutionTree,
+ void checkMixinSuperUses(TreeElements elements,
MixinApplicationElement mixinApplication, ClassElement mixin) {
// TODO(johnniwinther): Avoid the use of [TreeElements] here.
- if (resolutionTree == null) return;
- Iterable<SourceSpan> superUses = resolutionTree.superUses;
+ Iterable<SourceSpan> superUses = elements.superUses;
if (superUses.isEmpty) return;
DiagnosticMessage error = reporter.createMessage(mixinApplication,
MessageKind.ILLEGAL_MIXIN_WITH_SUPER, {'className': mixin.name});
« no previous file with comments | « pkg/compiler/lib/src/resolution/operators.dart ('k') | pkg/compiler/lib/src/serialization/element_serialization.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698