[go-nuts] is there bug with keyword "select" implementation?

2016-12-09 Thread Dave Cheney
Have you checked that your code is free of data races? The total == 0 condition would be my guess for a potential data race. -- 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

Re: [go-nuts] is there bug with keyword "select" implementation?

2016-12-08 Thread Ian Lance Taylor
On Thu, Dec 8, 2016 at 7:44 PM, Freeman Feng wrote: > > I found that if I use timeout mixed with another chan which is heavily > communicated with other goroutines, it could lead to dead lock or something > inside select > > Here is the codes: > > for { > select { > case x

[go-nuts] is there bug with keyword "select" implementation?

2016-12-08 Thread Freeman Feng
Hello, I found that if I use timeout mixed with another chan which is heavily communicated with other goroutines, it could lead to dead lock or something inside select Here is the codes: for { select { case x := <-ch: // handling business logic begin (about 38+ message pushed to this chan at