3 ms·
Such as?
by shakow 6y ago
Such as?
- pjmlp 6y agoAny blog post that gives examples accessing shared variables and never goes beyond anything else, leaving to the reader that it works the same way regardless of what resources are being accessed. https://blog.knoldus.com/how-we-can-do-fearless-concurrency-in-rust/ https://blog.knoldus.com/how-we-can-do-fearless-concurrency-... Now rewrite the same blog post using SQL queries to update the same counter variable on a table row. The Rustonomicon is quite clear that it wouldn't work, > However Rust does not prevent general race conditions. https://doc.rust-lang.org/nomicon/races.html https://doc.rust-lang.org/nomicon/races.html
- shakow 6y agoYou really had to dig a post that has less text than code? > leaving to the reader that it works the same way regardless of what resources are being accessed. If that's how readers envision that non-language-managed resources work, they should go back to CS102 right now. And concerning the nomicon, it explicitly states that Rust can't handle all races condition, I don't get your point.