Index: pkg/analyzer/test/src/task/strong/inferred_type_test.dart |
diff --git a/pkg/analyzer/test/src/task/strong/inferred_type_test.dart b/pkg/analyzer/test/src/task/strong/inferred_type_test.dart |
index 65686c5511a6f7227aec225fda3d709d1a2e82d8..b64a5b664f1e2d707e2bb793b840e0b203d37dba 100644 |
--- a/pkg/analyzer/test/src/task/strong/inferred_type_test.dart |
+++ b/pkg/analyzer/test/src/task/strong/inferred_type_test.dart |
@@ -3570,6 +3570,19 @@ var f = /*warning:UNSAFE_BLOCK_CLOSURE_INFERENCE, |
expect(f.type.toString(), '() → Null'); |
} |
+ test_inferredType_cascade() async { |
+ var mainUnit = await checkFileElement(''' |
+class A { |
+ int a; |
+ List<int> b; |
+ void m() {} |
+} |
+var v = new A()..a = 1..b.add(2)..m(); |
+'''); |
+ var v = mainUnit.topLevelVariables[0]; |
+ expect(v.type.toString(), 'A'); |
+ } |
+ |
test_inferredType_customBinaryOp() async { |
var mainUnit = await checkFileElement(''' |
class C { |