Index: sdk/lib/async/future.dart |
diff --git a/sdk/lib/async/future.dart b/sdk/lib/async/future.dart |
index 5d6a65009a4afae64ff5d150d7d8816bc876526f..a60a57854ae4c0d99e82b15a820c6ae10a524769 100644 |
--- a/sdk/lib/async/future.dart |
+++ b/sdk/lib/async/future.dart |
@@ -521,11 +521,12 @@ abstract class Future<T> { |
* If this future does not complete before `timeLimit` has passed, |
* the [onTimeout] action is executed instead, and its result (whether it |
* returns or throws) is used as the result of the returned future. |
+ * The result of the [onTimeout] function must return a [T] or a `Future<T>`. |
Lasse Reichstein Nielsen
2016/02/09 16:37:05
either "the [onTimeout] function must return"
or "
floitsch
2016/02/09 17:04:21
Done.
|
* |
* If `onTimeout` is omitted, a timeout will cause the returned future to |
* complete with a [TimeoutException]. |
*/ |
- Future timeout(Duration timeLimit, {onTimeout()}); |
+ Future<T> timeout(Duration timeLimit, {onTimeout()}); |
} |
/** |