3 ms·
What about when you want a concurrency safe language? You can still have concurrency bugs, like race conditions in languages that are only memory safe.
by vardump 8y ago
What about when you want a concurrency safe language? You can still have concurrency bugs, like race conditions in languages that are only memory safe.
- PopsiclePete 8y agoOf all the stories Rust tries to sell me on, concurrency is by far the weakest of all. Rust concurrency is a mess compared to (yes, I'm going to say it) Go. Async/await are still far away from being anywhere near figured out nor implemented, CSP primitives in the std. lib like std::mpsc are basically DOA/obsolete/half-functioning and tokio/futures are still early alpha. There's a lot more to concurrency than just compile-time verification of safe usage of a mutex or moving data in/out of a thread. A lot more.
- est31 8y agoDon't get what you mean by std::mpsc being half-functioning. I'm using it and it works great. Obsolete, maybe. There are alternative implementations out there that have various improvements, but any non-trivial core primitive of a healthy language has that, no?
- vardump 8y agoI actually agree with you. I'll just gladly take any available advances in concurrency safety. In any concurrency models, including shared data. Async/await (and production quality gRPC) is currently what's keeping us from using Rust at dayjob. > There's a lot more to concurrency than just compile-time verification of safe usage of a mutex or moving data in/out of a thread. A lot more. Sure, but it's better to have at least that.
- zozbot123 8y agoRust does not solve all race conditions, unfortunately. Even world domination has its limits! It does solve simple data races, which means that use of concurrency within Safe Rust is indeed memory safe. This is better than what some other languages can claim, such as Go (only the _sequential_ subset of Go is memory safe)!
- rurban 8y agoThen use a concurrency safe language. There are plenty of slow ones (pass by copy) and even some supporting references into shared memory. I would also emphasis the need for type safety and contracts.