News for hackers. Stuff that matters.
Re:Some notes on Rust by pcwalton on Sunday February 01, 2015 @11:31AM (#8980503)
> What? C++11/14 solves these issues.

You're right that C++ provides a solution to the first two, but C++ locking via std::mutex isn't done in the same way as Rust: in Rust the mutex owns the data and prevents you from getting access to it unless you lock. std::mutex, however, is a separate value from the data it protects and it's up to you to coordinate access to that data.

I would also argue that Rust is a better solution to the first two issues. Modern C++ does not solve the problem of use-after-free (dangling references and invalid iterators are very possible, and common in large codebases). This is something that I don't believe C++ can solve without becoming a radically different language. Furthermore, Rust forces you to use the right patterns unless you type "unsafe": this is, again, important for security, reliability, and developer productivity, reducing the amount of time you spend in the debugger.

Re:Some notes on Rust by zanny on Sunday February 01, 2015 @01:45PM (#8981093)
My simplification of matters is that while C++ can now do everything right, it still easily lets you do everything wrong.

Rust compels correctness, so for any project where you can't trust your coworkers aptitude towards correctness (and that is to say you even trust your own) Rust is an insane productivity booster. We could have avoided millions of hours of work and thousands of zero day and system destroying bugs if we had OS cores written in a language like Rust.

Re:Some notes on Rust by ssalazar on Sunday February 01, 2015 @03:28PM (#8981525)
> so for any project where you can't trust your coworkers aptitude towards correctness

So, for any non-trivial project. People will make mistakes, no matter how skilled or experienced they are. Catching these mistakes at compile-time can be a huge gain for security and stability.

Though it remains to be seen is what kind of maintenance/development burden these constraints introduce over the longer term lifecycle of a software project.

Re:Some notes on Rust by copsarebastards on Sunday February 01, 2015 @12:51PM (#8980863)
Also, it's worth noting that "C++ provides a solution" is not "C++ solves these issues". Somewhere in any C++ codebase of significant size, someone has done it wrong and the compiler isn't going to tell you where.
Re:Some notes on Rust by Q6T46nT668w6i3m on Sunday February 01, 2015 @12:32PM (#8980784)
Fair points

Rust’s synchronization primitives are immature — they’ve been rewritten once or twice in the past year or so — but cool from a usability perspective.

edit: oh, hello pcwalton. I suspect you knew this already. :P

Re:Some notes on Rust by Ygg2 on Sunday February 01, 2015 @02:21PM (#8981253)
[Citation needed]
Re:Some notes on Rust by Q6T46nT668w6i3m on Sunday February 01, 2015 @04:44PM (#8981787)
?
Re:Some notes on Rust by Ygg2 on Monday February 02, 2015 @12:30AM (#8982852)
Based on what did you concludes that?