News for hackers. Stuff that matters.
Re:Rust 0.9 released by lmm on Thursday January 09, 2014 @07:20PM (#7034212)
There'll always be some place for manual memory management - and if the languages for it get better then that space gets wider. I like the fact that they're taking typing seriously, but assuming you don't need the manual memory management I've yet to see any examples of where Rust wins over Haskell/Scala/F#, or even OCaml (though I could well believe it would perform better).
Re:Rust 0.9 released by pcwalton on Thursday January 09, 2014 @07:29PM (#7034248)
I'd say concurrency support is a big one: Rust rules out data races at compile time, eliminating the need for race detectors, while ensuring that you still have the full array of options when it comes to shared memory, locks, and so on.
Re:Rust 0.9 released by lmm on Friday January 10, 2014 @06:05AM (#7036065)
What do you mean by "rules out data races"? If I have one piece of code that writes two variables and another that reads them on another thread, there's no way for the compiler to know whether those two changes need to be atomic, serialized, or uncoordinated.
Re:Rust 0.9 released by pcwalton on Friday January 10, 2014 @01:04PM (#7038189)
Access to shared mutable memory without use of a synchronization primitive. It's the same definition data race detectors use.
Re:Rust 0.9 released by dbaupp on Friday January 10, 2014 @07:40AM (#7036311)
I believe the "data race" definition pcwalton is using is the one from C++11: "a race condition between non-atomic variables". http://en.wikipedia.org/wiki/Race_condition#C.2B.2B
Re:Rust 0.9 released by samnardoni on Friday January 10, 2014 @07:49AM (#7036333)
2 threads can't access the same variable in Rust without unsafe{}. I think, anyway...