seems I know what is wrong: my timer is not an *active* one.

在 2016年12月13日星期二 UTC+8下午3:09:30,sleepy写道:
>
> from the documentation of *func (*Timer) Reset 
> <https://golang.org/pkg/time/#Timer.Reset>*
>
>>
>> To reuse an active timer, always call its Stop method first and—if it had 
>> expired—drain the value from its channel. For example:
>> if !t.Stop() {
>>  <-t.C
>> }
>> t.Reset(d)
>>
>
> but my code blocks at the line "<-t.C"
>
> code at: https://play.golang.org/p/8XjpvMFt_2
>
> could anyone help me out? thanks.
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to