Index: editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/CompileTimeErrorCodeTest.java |
diff --git a/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/CompileTimeErrorCodeTest.java b/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/CompileTimeErrorCodeTest.java |
index 5154738c5dd16af1502cb9ec4a471fe181bb1ade..ed8f62acf620d154eb67d4efe33a678467b3ff02 100644 |
--- a/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/CompileTimeErrorCodeTest.java |
+++ b/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/CompileTimeErrorCodeTest.java |
@@ -700,6 +700,24 @@ public class CompileTimeErrorCodeTest extends ResolverTestCase { |
verify(source); |
} |
+ public void test_constMapKeyTypeImplementsEquals_factory() throws Exception { |
+ Source source = addSource(createSource(// |
+ "class A { const factory A() = B; }", |
+ "", |
+ "class B implements A {", |
+ " const B();", |
+ "", |
+ " operator ==(o) => true;", |
+ "}", |
+ "", |
+ "main() {", |
+ " var m = const { const A(): 42 };", |
+ "}")); |
+ resolve(source); |
+ assertErrors(source, CompileTimeErrorCode.CONST_MAP_KEY_EXPRESSION_TYPE_IMPLEMENTS_EQUALS); |
+ verify(source); |
+ } |
+ |
public void test_constMapKeyTypeImplementsEquals_super() throws Exception { |
Source source = addSource(createSource(// |
"class A {", |