Index: pkg/analyzer/test/src/task/strong/checker_test.dart |
diff --git a/pkg/analyzer/test/src/task/strong/checker_test.dart b/pkg/analyzer/test/src/task/strong/checker_test.dart |
index d8fb80c7ac9a4fadd0aab612139a1d907e50e774..bb8216a0b18875a5b6bdae1554c5fcedce68c106 100644 |
--- a/pkg/analyzer/test/src/task/strong/checker_test.dart |
+++ b/pkg/analyzer/test/src/task/strong/checker_test.dart |
@@ -964,6 +964,16 @@ void main() { |
''' |
}); |
+ testChecker('Function subtyping: uninferred closure', { |
+ '/main.dart': ''' |
+ typedef num Num2Num(num x); |
+ void main() { |
+ Num2Num g = /*info:INFERRED_TYPE_CLOSURE,severe:STATIC_TYPE_ERROR*/(int x) { return x; }; |
+ print(g(42)); |
+ } |
+ ''' |
+ }); |
+ |
testChecker('Relaxed casts', { |
'/main.dart': ''' |