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

Unified Diff: sdk/lib/async/stream_impl.dart

Issue 2959163002: Make Zone API strong mode clean. (Closed)
Patch Set: Created 3 years, 6 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
« no previous file with comments | « sdk/lib/async/schedule_microtask.dart ('k') | sdk/lib/async/timer.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/async/stream_impl.dart
diff --git a/sdk/lib/async/stream_impl.dart b/sdk/lib/async/stream_impl.dart
index b5e89c17f52d5d653ba8f28fe85e8b4423f74052..1ce2acf6846332e2d5617df94cc6bb7e3876ecb2 100644
--- a/sdk/lib/async/stream_impl.dart
+++ b/sdk/lib/async/stream_impl.dart
@@ -332,7 +332,7 @@ class _BufferingStreamSubscription<T>
_checkState(wasInputPaused);
}
- void _sendError(var error, StackTrace stackTrace) {
+ void _sendError(Object error, StackTrace stackTrace) {
assert(!_isCanceled);
assert(!_isPaused);
assert(!_inCallback);
@@ -345,12 +345,11 @@ class _BufferingStreamSubscription<T>
_state |= _STATE_IN_CALLBACK;
// TODO(floitsch): this dynamic should be 'void'.
if (_onError is ZoneBinaryCallback<dynamic, Object, StackTrace>) {
- ZoneBinaryCallback<dynamic, Object, StackTrace> errorCallback = _onError
- as Object/*=ZoneBinaryCallback<dynamic, Object, StackTrace>*/;
+ ZoneBinaryCallback<dynamic, Object, StackTrace> errorCallback =
+ _onError;
_zone.runBinaryGuarded(errorCallback, error, stackTrace);
} else {
- _zone.runUnaryGuarded<dynamic, Object>(
- _onError as Object/*=ZoneUnaryCallback<dynamic, Object>*/, error);
+ _zone.runUnaryGuarded<Object>(_onError, error);
}
_state &= ~_STATE_IN_CALLBACK;
}
« no previous file with comments | « sdk/lib/async/schedule_microtask.dart ('k') | sdk/lib/async/timer.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698