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

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

Issue 1120633002: Refactor index operator in SimpleTypeInferrer. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix bug. Created 5 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/send_resolver.dart
diff --git a/pkg/compiler/lib/src/resolution/send_resolver.dart b/pkg/compiler/lib/src/resolution/send_resolver.dart
index b8eeb2fed37369f53c94d4f66365632b04a4e9ed..a49fed7c7d81b6092e5599553fd1e58d895b2917 100644
--- a/pkg/compiler/lib/src/resolution/send_resolver.dart
+++ b/pkg/compiler/lib/src/resolution/send_resolver.dart
@@ -340,11 +340,24 @@ abstract class SendResolverMixin {
}
} else if (node.isSuperCall) {
if (Elements.isUnresolved(element)) {
- return new StaticAccess.unresolvedSuper(element);
+ if (isCompound) {
+ if (Elements.isUnresolved(getter)) {
+ // TODO(johnniwinther): Ensure that [getter] is not null. This
+ // happens in the case of missing super getter.
+ return new CompoundAccessSemantics(
+ CompoundAccessKind.SUPER_UNRESOLVED_GETTER, getter, element);
+ } else {
+ return new CompoundAccessSemantics(
+ CompoundAccessKind.SUPER_UNRESOLVED_SETTER, getter, element);
+ }
+ } else {
+ return new StaticAccess.unresolvedSuper(element);
+ }
} else if (isCompound && Elements.isUnresolved(getter)) {
// TODO(johnniwinther): Ensure that [getter] is not null. This happens
// in the case of missing super getter.
- return new StaticAccess.unresolved(getter);
+ return new CompoundAccessSemantics(
+ CompoundAccessKind.SUPER_UNRESOLVED_GETTER, getter, element);
} else if (element.isField) {
if (getter != null && getter != element) {
CompoundAccessKind accessKind;

Powered by Google App Engine
This is Rietveld 408576698