| Index: compiler/javatests/com/google/dart/compiler/resolver/NegativeResolverTest.java
|
| diff --git a/compiler/javatests/com/google/dart/compiler/resolver/NegativeResolverTest.java b/compiler/javatests/com/google/dart/compiler/resolver/NegativeResolverTest.java
|
| index 85e5240710eb20d89e07fe1e1cdee5269e845a02..f98483b1baf2fd04e0a0df174941fa19817f31bb 100644
|
| --- a/compiler/javatests/com/google/dart/compiler/resolver/NegativeResolverTest.java
|
| +++ b/compiler/javatests/com/google/dart/compiler/resolver/NegativeResolverTest.java
|
| @@ -1074,4 +1074,16 @@ public class NegativeResolverTest extends CompilerTestCase {
|
| "class MyClass implements Map<Object, Dynamic> {",
|
| "}"));
|
| }
|
| +
|
| + public void testConstructorDuplicateInitializationTest() {
|
| + checkSourceErrors(
|
| + makeCode(
|
| + "class A {",
|
| + " A.one(this.x) : this.x = 42;",
|
| + " A.two(y) : this.x = y, x = y;",
|
| + " var x;",
|
| + "}"),
|
| + errEx(ResolverErrorCode.DUPLICATE_INITIALIZATION, 2, 19, 11),
|
| + errEx(ResolverErrorCode.DUPLICATE_INITIALIZATION, 3, 26, 5));
|
| + }
|
| }
|
|
|