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 4490b8870d37d0a1b1dfdcd02c7bbfc100145ce7..6c4f90b232c6adb126da9a4910fc1e7a5a8b5bb2 100644 |
--- a/pkg/compiler/lib/src/resolution/resolution.dart |
+++ b/pkg/compiler/lib/src/resolution/resolution.dart |
@@ -856,7 +856,7 @@ class ResolverTask extends CompilerTask { |
if (lookupElement == null) { |
reporter.internalError(member, |
"No abstract field for accessor"); |
- } else if (!identical(lookupElement.kind, ElementKind.ABSTRACT_FIELD)) { |
+ } else if (!lookupElement.isAbstractField) { |
if (lookupElement.isMalformed || lookupElement.isAmbiguous) return; |
reporter.internalError(member, |
"Inaccessible abstract field for accessor"); |
@@ -869,14 +869,14 @@ class ResolverTask extends CompilerTask { |
if (setter == null) return; |
int getterFlags = getter.modifiers.flags | Modifiers.FLAG_ABSTRACT; |
int setterFlags = setter.modifiers.flags | Modifiers.FLAG_ABSTRACT; |
- if (!identical(getterFlags, setterFlags)) { |
+ if (getterFlags != setterFlags) { |
final mismatchedFlags = |
new Modifiers.withFlags(null, getterFlags ^ setterFlags); |
- reporter.reportErrorMessage( |
+ reporter.reportWarningMessage( |
field.getter, |
MessageKind.GETTER_MISMATCH, |
{'modifiers': mismatchedFlags}); |
- reporter.reportErrorMessage( |
+ reporter.reportWarningMessage( |
field.setter, |
MessageKind.SETTER_MISMATCH, |
{'modifiers': mismatchedFlags}); |