| 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 afbb123a434f08ddead09e501780a8a9a003e6eb..ea653ec9bc8c8a7e234bacd838d2245c04efc450 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
|
| @@ -3233,6 +3233,25 @@ public class CompileTimeErrorCodeTest extends ResolverTestCase {
|
| verify(source);
|
| }
|
|
|
| + public void test_typeAliasCannotRereferenceItself_mixin_direct() throws Exception {
|
| + Source source = addSource(createSource(//
|
| + "typedef M = Object with M;"));
|
| + resolve(source);
|
| + assertErrors(CompileTimeErrorCode.TYPE_ALIAS_CANNOT_REFERENCE_ITSELF);
|
| + verify(source);
|
| + }
|
| +
|
| + public void test_typeAliasCannotRereferenceItself_mixin_indirect() throws Exception {
|
| + Source source = addSource(createSource(//
|
| + "typedef M1 = Object with M2;",
|
| + "typedef M2 = Object with M1;"));
|
| + resolve(source);
|
| + assertErrors(
|
| + CompileTimeErrorCode.TYPE_ALIAS_CANNOT_REFERENCE_ITSELF,
|
| + CompileTimeErrorCode.TYPE_ALIAS_CANNOT_REFERENCE_ITSELF);
|
| + verify(source);
|
| + }
|
| +
|
| public void test_typeArgumentNotMatchingBounds_const() throws Exception {
|
| Source source = addSource(createSource(//
|
| "class A {}",
|
|
|