Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(28)

Unified Diff: pkg/analyzer/test/src/task/strong/checker_test.dart

Issue 2651653006: Make Future.value() constructor in MockSdk consistent with the actual SDK. (Closed)
Patch Set: Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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 9401f1a6a52ed166afadc16ec48626094703c90a..a788da18a9d26cc41553afda8b9482b744e77b99 100644
--- a/pkg/analyzer/test/src/task/strong/checker_test.dart
+++ b/pkg/analyzer/test/src/task/strong/checker_test.dart
@@ -937,16 +937,16 @@ dynamic x;
foo1() async => x;
Future foo2() async => x;
Future<int> foo3() async => x;
-Future<int> foo4() async => new Future<int>.value(/*info:DYNAMIC_CAST*/x);
+Future<int> foo4() async => new Future<int>.value(x);
Future<int> foo5() async =>
- /*error:RETURN_OF_INVALID_TYPE*/new Future<String>.value(/*info:DYNAMIC_CAST*/x);
+ /*error:RETURN_OF_INVALID_TYPE*/new Future<String>.value(x);
bar1() async { return x; }
Future bar2() async { return x; }
Future<int> bar3() async { return x; }
-Future<int> bar4() async { return new Future<int>.value(/*info:DYNAMIC_CAST*/x); }
+Future<int> bar4() async { return new Future<int>.value(x); }
Future<int> bar5() async {
- return /*error:RETURN_OF_INVALID_TYPE*/new Future<String>.value(/*info:DYNAMIC_CAST*/x);
+ return /*error:RETURN_OF_INVALID_TYPE*/new Future<String>.value(x);
}
int y;
« no previous file with comments | « pkg/analyzer/test/src/context/mock_sdk.dart ('k') | pkg/analyzer/test/src/task/strong/inferred_type_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698