News for hackers. Stuff that matters.
Re:Linus Torvalds on semaphores (1999) by Animats on Wednesday December 17, 2014 @05:07PM (#8764645)
Termination in queued systems is moderately hard. You have to drain out the queues. In Go, you can close a channel at the write end and wait for the reader to reach EOF. But if the reader is stuck waiting for something, there's a problem. Especially if it's waiting to write another channel. If you close a channel written by another task, that task will panic when it writes to the closed channel. You can't close channels to force shutdown in Go unless a panic is acceptable.

This is a classic problem with bounded buffers, re-invented four decades later.

There are no comments on this comment yet.