News for hackers. Stuff that matters.
Re:Writing comments about pointer ownership by crystalgiver on Sunday August 23, 2015 @01:04PM (#10106012)
Ugh, if you bring up Rust in this thread it's clear you have little to no experience actually writing large amounts of system-level code. Rust has been around for all 2-3 years now? 1.0 for what? Months? What large successful Rust code bases have you worked on? What have you actually built with Rust?

C++ is for people who work on large mature codebases, deal with practical issues, and actually build stuff. Talk to me about the virtues of Rust when you actually have real experience.

Re:Writing comments about pointer ownership by pcwalton on Sunday August 23, 2015 @02:10PM (#10106254)
> What large successful Rust code bases have you worked on? What have you actually built with Rust?

> C++ is for people who work on large mature codebases, deal with practical issues, and actually build stuff. Talk to me about the virtues of Rust when you actually have real experience.

According to the GitHub stats, I've added 293,494 lines of Rust code to Servo and 381,084 lines of code (mostly Rust) to the Rust compiler. I find that Rust's pointer ownership rules help improve the reliability and security of my code significantly.

Re:Writing comments about pointer ownership by crystalpsychic on Sunday August 23, 2015 @04:04PM (#10106582)
Your Rust stats are irrelevant. You're literally the creator of Rust.

Outside of you, the majority of "users" of Rust are script-kiddies who think it's "cool" (like Haskell cool) and will likely never write any native application of any significance using it (or any low-level language for that matter).

Re:Writing comments about pointer ownership by kibwen on Sunday August 23, 2015 @06:04PM (#10106900)
Given that you seem to think that pcwalton is the creator of Rust, I'm guessing that your professed knowledge of the demographics of the Rust community is also entirely fantastical. Would you like to cite a source for your ad-hominem throwaway comments?
Re:Writing comments about pointer ownership by crystalgiver on Sunday August 23, 2015 @06:21PM (#10106954)
I think rust has its merits, don't get me wrong. I just think it has a large cargo cult following of inexperienced script kids who have never used it for anything other than pretending to know what they're taking about.
Re:Writing comments about pointer ownership by kibwen on Sunday August 23, 2015 @07:50PM (#10107235)
And what makes you think that?
Re:Writing comments about pointer ownership by nice_byte on Sunday August 23, 2015 @03:16PM (#10106438)
I believe bringing up Rust in a discussion like this is completely warranted. After all, both Rust and C++ try to achieve similar goals (C++ also has a goal of maintaining backward compatibility with decades worth of code, which Rust doesn't yet have). Rust might not be quite there yet, but I believe the future is either Rust (or other similar language) becoming "mainstream", or C++ changing radically (and offering a "compatibility mode", perhaps).
Re:Writing comments about pointer ownership by steveklabnik on Sunday August 23, 2015 @03:04PM (#10106413)

    > Rust has been around for all 2-3 years now? 1.0 for what? Months? 
Rust as a project has been around for eight years in total, about twoish in a similar fashion to what it is today. It's been 1.0 for three months.
Re:Writing comments about pointer ownership by kazinator on Sunday August 23, 2015 @02:38PM (#10106333)
> C++ is for people who work on large mature codebases

Sure, C++98 or C++03.

Re:Writing comments about pointer ownership by nice_byte on Sunday August 23, 2015 @02:52PM (#10106388)
While it's true that most people have to deal with lots of legacy code, as long as their compilers are up-to-date, it doesn't prevent them from using new language features.
Re:Writing comments about pointer ownership by pavlov on Sunday August 23, 2015 @03:05PM (#10106416)
In practice it often does, because introducing brand new patterns alongside existing ones may be frowned upon in a large project.

Consider a codebase that uses the "comment indicates ownership transfer" pattern everywhere. Would it improve the code quality if one developer suddenly introduced unique_ptr, std::move and rvalue references in just one place in the API, when every other call would still be using the old style?

To my taste, the mental overhead of having two different ownership patterns would outweigh the advantage of the new compiler checks (which in this case would be mostly theoretical, since the devs working on this project would presumably feel at home with the old pattern).