4 ms·
I'm curious what's the issue with go routine and what kind of fix ADA bring?
by wejick 6y ago
I'm curious what's the issue with go routine and what kind of fix ADA bring?
- boyter 6y agoNot familiar with Ada but the inability to stop running goroutines from outside it is annoying and leads to a lot of state telling them to exit. Sometimes I just want it to stop now.
- wejick 6y agoIt's not like on pthread where we have a trhead handler, that will complicate many things. Like you said, We stop the go routine by telling it to exit the function, it's quite straightforward I think. Not more than a channel and switch case (+ context)
- rbranson 6y agoHow would you expect that to actually work though? If a goroutine could be arbitrarily stopped at any point, that would trivially lead to degenerate program states. A lock could be held open or another goroutine could be waiting on it for a message.