| Index: compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerCompilerTest.java
|
| diff --git a/compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerCompilerTest.java b/compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerCompilerTest.java
|
| index 65b4c8d428b006ab353ff5020afde52a6937086a..6e1794ced91fd8b5975feab6ac2b86581472a9ad 100644
|
| --- a/compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerCompilerTest.java
|
| +++ b/compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerCompilerTest.java
|
| @@ -3225,7 +3225,7 @@ public class TypeAnalyzerCompilerTest extends CompilerTestCase {
|
| errEx(ParserErrorCode.EXTERNAL_ONLY_METHOD, 5, 16, 6),
|
| errEx(ParserErrorCode.EXTERNAL_ONLY_METHOD, 6, 16, 6));
|
| }
|
| -
|
| +
|
| /**
|
| * Methods with "external" cannot have body.
|
| */
|
| @@ -3249,6 +3249,46 @@ public class TypeAnalyzerCompilerTest extends CompilerTestCase {
|
| errEx(ParserErrorCode.EXTERNAL_ABSTRACT, 7, 12, 8));
|
| }
|
|
|
| + /**
|
| + * <p>
|
| + * http://code.google.com/p/dart/issues/detail?id=4315
|
| + */
|
| + public void test_cascade_propertyAccess() throws Exception {
|
| + AnalyzeLibraryResult libraryResult = analyzeLibrary(
|
| + "// filler filler filler filler filler filler filler filler filler filler",
|
| + "class A {",
|
| + " int f;",
|
| + "}",
|
| + "main() {",
|
| + " A a = new A();",
|
| + " a",
|
| + " ..f = 1",
|
| + " ..f = 2;",
|
| + "}",
|
| + "");
|
| + assertErrors(libraryResult.getErrors());
|
| + }
|
| +
|
| + /**
|
| + * <p>
|
| + * http://code.google.com/p/dart/issues/detail?id=4315
|
| + */
|
| + public void test_cascade_methodInvocation() throws Exception {
|
| + AnalyzeLibraryResult libraryResult = analyzeLibrary(
|
| + "// filler filler filler filler filler filler filler filler filler filler",
|
| + "class A {",
|
| + " int m() {}",
|
| + "}",
|
| + "main() {",
|
| + " A a = new A();",
|
| + " a",
|
| + " ..m()",
|
| + " ..m();",
|
| + "}",
|
| + "");
|
| + assertErrors(libraryResult.getErrors());
|
| + }
|
| +
|
| private static <T extends DartNode> T findNode(
|
| AnalyzeLibraryResult libraryResult,
|
| final Class<T> clazz,
|
|
|