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

Unified Diff: pkg/analyzer/lib/src/generated/testing/test_type_provider.dart

Issue 898513002: Fix async/await type checking in analyzer. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Reformat and sort methods Created 5 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/lib/src/generated/testing/test_type_provider.dart
diff --git a/pkg/analyzer/lib/src/generated/testing/test_type_provider.dart b/pkg/analyzer/lib/src/generated/testing/test_type_provider.dart
index 8cd47724eabc95728e51f4d0fca0cfd6d9bc4e20..9a719d4acb92ff7b60d8fa3da9376fc47f2ae17d 100644
--- a/pkg/analyzer/lib/src/generated/testing/test_type_provider.dart
+++ b/pkg/analyzer/lib/src/generated/testing/test_type_provider.dart
@@ -47,6 +47,11 @@ class TestTypeProvider implements TypeProvider {
InterfaceType _functionType;
/**
+ * THe type representing the built-in type 'Future'
+ */
+ InterfaceType _futureType;
+
+ /**
* The type representing the built-in type 'int'.
*/
InterfaceType _intType;
@@ -172,6 +177,14 @@ class TestTypeProvider implements TypeProvider {
}
@override
+ InterfaceType get futureType {
+ if (_futureType == null) {
+ _futureType = ElementFactory.classElement2("Future", ["T"]).type;
+ }
+ return _futureType;
+ }
+
+ @override
InterfaceType get intType {
if (_intType == null) {
_initializeNumericTypes();

Powered by Google App Engine
This is Rietveld 408576698