time: add AfterFunc to call a function after a given duration.
The After code is trivially generalisable to provide support for this, and it is possible to use AfterFunc to do things that After cannot, such as waiting for many events at varied times without an overhead of one goroutine per event. R=rsc, r CC=golang-dev https://golang.org/cl/3905041
Showing
Please register or sign in to comment