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

Unified Diff: pkg/analyzer/lib/src/summary/link.dart

Issue 2581803002: Add access to FutureOr in TypeProviders (and add implementation in mock sdks) (Closed)
Patch Set: Created 4 years 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/summary/link.dart
diff --git a/pkg/analyzer/lib/src/summary/link.dart b/pkg/analyzer/lib/src/summary/link.dart
index 1e375c9e82d242db122dcf1986647a4fdc824461..3bd5ba3cca2ba55fc69b7fd259a5cf0efcbd7a21 100644
--- a/pkg/analyzer/lib/src/summary/link.dart
+++ b/pkg/analyzer/lib/src/summary/link.dart
@@ -4656,6 +4656,7 @@ class TypeProviderForLink extends TypeProviderBase {
InterfaceType _functionType;
InterfaceType _futureDynamicType;
InterfaceType _futureNullType;
+ InterfaceType _futureOrType;
InterfaceType _futureType;
InterfaceType _intType;
InterfaceType _iterableDynamicType;
@@ -4705,6 +4706,10 @@ class TypeProviderForLink extends TypeProviderBase {
_futureNullType ??= futureType.instantiate(<DartType>[nullType]);
@override
+ InterfaceType get futureOrType =>
+ _futureOrType ??= _buildInterfaceType(_linker.asyncLibrary, 'Future');
scheglov 2016/12/15 20:47:58 'FutureOr'?
Brian Wilkerson 2016/12/15 20:54:39 Good catch. Done.
+
+ @override
InterfaceType get futureType =>
_futureType ??= _buildInterfaceType(_linker.asyncLibrary, 'Future');
« no previous file with comments | « pkg/analyzer/lib/src/generated/testing/test_type_provider.dart ('k') | pkg/analyzer/lib/src/summary/summary_sdk.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698