Index: tool/input_sdk/lib/async/timer.dart |
diff --git a/tool/input_sdk/lib/async/timer.dart b/tool/input_sdk/lib/async/timer.dart |
index fafe65228db5060519b0498e950edbd4347e6fe2..1bbb65b93307a81837011043cd1f72c014010bdd 100644 |
--- a/tool/input_sdk/lib/async/timer.dart |
+++ b/tool/input_sdk/lib/async/timer.dart |
@@ -76,8 +76,11 @@ abstract class Timer { |
// be invoked in the root zone. |
return Zone.current.createPeriodicTimer(duration, callback); |
} |
- return Zone.current.createPeriodicTimer( |
- duration, Zone.current.bindUnaryCallback(callback, runGuarded: true)); |
+ // TODO(floitsch): the return type should be 'void', and the type |
+ // should be inferred. |
+ var boundCallback = Zone.current.bindUnaryCallback/*<dynamic, Timer>*/( |
+ callback, runGuarded: true); |
+ return Zone.current.createPeriodicTimer(duration, boundCallback); |
} |
/** |