|
|
|
|
|
by armitron
1326 days ago
|
|
"I think goroutines are preferable in that context because async/await is a much lower level tool that is easy to misuse, but when it comes to writing code with critical requirements of correctness and efficiency, you need async/await and you need Zig’s philosophy that we all should strive to write robust, optimal, and reusable software." I don't see how this follows. Async/await is a disaster in every way, M:N threading (which Goroutines are an implementation of) is the way to go. Not only does one get sane concurrency but also parallelism. Look at Ada tasks and Erlang processes for writing parallel code with critical requirements of correctness and efficiency. |
|
This is not something that a systems programming language would want to do. I agree with your point that structured concurrency is good and preferable for high-level languages, but it's not an absolute better choice when you start thinking about the details, like you have to do in a systems programming language.