News for hackers. Stuff that matters.
Re:Why I love Rust by hellofunk on Friday January 08, 2016 @03:43AM (#10863693)
I actually think you'd go far to spend 3 - 4 months learning C++. Almost every language you can likely encounter in your career will use some feature that will get introduced to you in C++, especially modern C++, and, almost any language will be easier to learn and use after first going through a C++ learning curve.

Besides, C++ is still the big player, more than all others. Even Apple's new language Swift is written in C++. It's a good language to know something about.

It also sets you into a different category of programmers, from what I have found recently, since C++ techniques are not taught much in college programs any more (based on my conversations with recent CS grads), which really surprises me. It's a special skill that would set you apart if you know it.

Re:Why I love Rust by wobbleblob on Friday January 08, 2016 @04:48AM (#10863880)
The problem is that C++ is a language where the "top 150,000 most essential things to get you started with C++" is a volume that spans several book shelves. Even Bjarne Stroustrup allegedly rated his own C++ skills at maybe 7 out of 10. If you start with C++, you're committed to a multi year project, that's what it takes to advance from novice to junior level.
Re:Why I love Rust by bluetomcat on Friday January 08, 2016 @05:02AM (#10863926)
The whole C++ language is indeed a monstrosity designed by a committee that resulted from years of piling up "requested features", but with "modern" C++14 they try to narrow-down the idiomatic constructs to a smaller, more manageable set.
Re:Why I love Rust by hellofunk on Friday January 08, 2016 @04:59AM (#10863915)
Sorry but this is just wrong. You do not need several years to get productive in C++. Very few professional C++ developers are using every feature of the language. You could spend a year mastering template metaprogramming alone, but do you need it? Not most of the time. Interfacing with good C++ libs (another reason to learn C++) does not require metaprogramming, and many other features fall into a the same category. Saying there are 150,000 required learning points is sensationalism and just downright false.
Re:Why I love Rust by wobbleblob on Friday January 08, 2016 @05:14AM (#10863955)
Junior level is when you know all language features, and are starting to learn the ecosystem of tools and libraries.

You're probably much smarter or more dedicated than me if you feel this level can be reached in a much shorter time.

Re:Why I love Rust by hellofunk on Friday January 08, 2016 @05:24AM (#10863991)
I think you are missing the point. It is widely understood in the C++ world that no one needs to know "all language features" and in reality, almost no one does. It's not a language where that is necessary or expected because the language is large and has a tremendous range of uses, and no one needs all of it for a particular project or focus.

But you can most certainly learn all the basics of writing good C++ code, and interop with great C++ libraries and get real stuff done, in fairly short time. It took me about a month to go from Objective-C to C++ and start publishing iOS apps written almost entirely in C++. And if you don't need that, you can start writing command-line utilities in a few days at most.

Re:Why I love Rust by cmollis on Friday January 08, 2016 @07:48AM (#10864468)
this is really true in my experience. I worked on a large server for a few years and most of my work was spent doing pretty mundane things (mostly interfacing with other libraries(apis)). I certainly didn't use every feature and, like you note, most programmers don't. Sometimes I would come across a new C++ capability that was utilized and I would just learn and utilize it, but this depended on the feature and situation. In fact, the only thing that's really different about it (at least to me), was the constant concern over memory usage (and all of the make/build stuff). These are just parts of the language that you need to consider that are avoided in other languages (the dirty secret here is that regardless of the language, you still need to consider them). I liked C/C++ because you can pretty much do anything with it, but you can get to certain points faster with a different language (again, depending on the target usage). Language platforms capture programmer inertia, which is why big companies try to own them. However, in reality, since there are so many, most good programmers seem to be able to switch between them fairly easily (which is a good thing).
Re:Why I love Rust by dagw on Friday January 08, 2016 @05:22AM (#10863981)
Junior level is when you know all language features

Wow, in that case I don't think I've ever worked with anybody who's ever managed to reach "junior level" in any language. What do you call someone with, for example, just a PhD in the relevant field, 6 or 7 years of professional programming experience and several successfully shipped products under his belt. And what do you call the guy that is obviously his junior?

Re:Why I love Rust by wobbleblob on Friday January 08, 2016 @08:33AM (#10864676)
When someone with a PhD in the relevant field, 6 or 7 years of professional programming experience and several successfully shipped products under his belt starts learning something new, he's a junior at that new thing.
Re:Why I love Rust by dagw on Friday January 08, 2016 @11:22AM (#10865964)
My point is that knowing all of a languages features is neither necessary nor sufficient for getting real work done even at the highest level. I've worked with some pretty smart and experienced people in my career and non of them would probably claim to know every single obscure corner of their favorite language.
Re:Why I love Rust by hnbro on Sunday January 10, 2016 @06:02PM (#10877672)
nice dodge. chewbacca defense!
Re:Why I love Rust by zvrba on Friday January 08, 2016 @05:01AM (#10863924)
> If you start with C++, you're committed to a multi year project, that's what it takes to advance from novice to junior level.

This is nonsense. Perhaps it's true to some degree if you try to "learn" C++ from tutorials of dubious quality rather than from a decent book.

Re:Why I love Rust by humanrebar on Friday January 08, 2016 @06:35AM (#10864179)
You sound like someone who has never really explored C++ lookup rules.
Re:Why I love Rust by zvrba on Friday January 08, 2016 @03:06PM (#10867793)
Funnily I've been working on MLOC-sized C++ projects and almost never had a problem with lookup rules. On rare occasions where it was a problem, it was a compile-time problem and easily resolved.

In any case, these rules do not fall under what I'd call "junior-level" C++ programmer as the OP wrote.

Re:Why I love Rust by jeremyjh on Friday January 08, 2016 @06:56AM (#10864263)
> If you start with C++, you're committed to a multi year project, that's what it takes to advance from novice to junior level.

This is ludicrous. Depending on your back-ground and the amount of time you spend working in the language each day, a journeyman level competency can be had in just a few months. Honestly this sounds like a comment from someone who has not done much C++. Please correct me if I'm wrong.

Re:Why I love Rust by humanrebar on Friday January 08, 2016 @07:00AM (#10864275)
I agree with GP and I've been doing C++ for a long time. There are a lot of dark corners that aren't a problem until they suddenly are. Most C++ devs don't really understand iterator invalidation, for example.
Re:Why I love Rust by pcwalton on Friday January 08, 2016 @11:51AM (#10866228)
Or undefined behavior.

I guess it can be summed up as: C++ is extremely good at making people think they're writing safe programs.

This feeling of safety is virtually always incorrect in the case of large-scale software, and the huge stream of memory-related vulnerabilities that virtually all popular network-facing C++ applications have and continue to have is proof of this. There is no reasonable way to argue against this; the fraction of popular network-facing C++ software written by a large team that have had memory safety problems rounds up to 100%.

Re:Why I love Rust by pcwalton on Friday January 08, 2016 @03:47AM (#10863706)
This is a weird answer to the question, especially since Rust very probably has whatever "modern C++ techniques" you were thinking of.
Re:Why I love Rust by Animats on Friday January 08, 2016 @03:55AM (#10863730)
Learning C++ means you have to learn a lot about how to debug C++, and understand exactly what's going on at the machine, OS, and debugger level. Whether this is a productive use of your life is up to you.
Re:Why I love Rust by hellofunk on Friday January 08, 2016 @03:48AM (#10863712)
I disagree. As others have pointed out, the demand for C++ jobs is still much higher than Rust jobs, so I think my answer still stands as a way to set yourself apart when thinking of a new language to spend a few months on.

Ideally, one would learn Rust and C++ both and see how they differ, and why.

Re:Why I love Rust by pcwalton on Friday January 08, 2016 @03:55AM (#10863727)
> I disagree. As others have pointed out, the demand for C++ jobs is still much higher than Rust jobs, so I think my answer still stands as a way to set yourself apart when thinking of a new language to spend a few months on.

It's not going to be a particularly interesting thread if everyone who works in a language that trends higher than Go on Google chimes in to say "you should learn my language instead, because it's more popular".

> Ideally, one would learn Rust and C++ both and see how they differ, and why.

Aside from uninteresting language-specific details, C++ essentially doesn't teach you anything that Rust doesn't.

Re:Why I love Rust by hellofunk on Friday January 08, 2016 @04:06AM (#10863753)
>It's not going to be a particularly interesting thread if everyone who works in a language that trends higher than Go on Google chimes in to say "you should learn my language instead, because it's more popular".

I think C++ is unique in that it is really not as popular as many new languages, not as trendy and as much in the news, and not even taught as much in college programs, yet, it remains the language where so many jobs are. This gives anyone with the desire to learn it a good and marketable skill that can make it possibly easier to find work and continue making a living doing software development. That does not apply to Rust, so I think it's a fair point to make to anyone who is asking about what languages are good to learn.

As for whether C++ has any techniques to teach that Rust does not, C++ is definitely a unique experience to go through and certainly gives a developer more insight into the actual machine they are working on in a way that few languages do.

Re:Why I love Rust by pcwalton on Friday January 08, 2016 @04:08AM (#10863758)
> it remains the language where so many jobs are

"The" language where so many jobs are? It's one of many.

> As for whether C++ has any techniques to teach that Rust does not, C++ is definitely a unique experience to go through and certainly gives a developer more insight into the actual machine they are working on in a way that few languages do.

Can you name, specifically, a way in which C++ gives you "more insight into the actual machine" compared to Rust?

Re:Why I love Rust by hellofunk on Friday January 08, 2016 @05:01AM (#10863920)
I think that Rust simplifies some things that you must do yourself in C++, and learning how to do them is valuable. At the very least, it will help you appreciate other languages, but it can also show you areas where you get manual control over performance in ways no other language offers.

And, perhaps most significantly, there are a wealth of C++ libraries out there that have no equivalent in other languages, and being able to use them is an education in itself.

Re:Why I love Rust by nickpsecurity on Friday January 08, 2016 @10:19AM (#10865433)
The C++ programmers here disagree given how often they point out that C++ close to the machine is actually the C style of programming done with C++ language. It's actively discouraged by the C++ community in favor of the C++ style of programming described in Modern C++, etc. The C++ style gives low-overhead abstractions that increase safety and maintainability (in theory) while aiming for C compatibility and performance. Main libraries and well-written apps are big on metaprogrammed constructs.

So, learning to code professional C++ will not help you understand machines more. You'd have to learn C, basic OS/CPU structures, and which compilers produce for certain C statements. Maybe read Write Great Code by Hyde or some online articles. Learn C++ to understand machines? Not happening unless you microprogram a CPU for it on a FPGA.

Re:Why I love Rust by yoklov on Friday January 08, 2016 @09:29AM (#10865040)
As someone who has written a lot of C++ (and essentially no rust), I think you're mischaracterizing C++. It has a lot of magic that the compiler does for you under the hood, and even more if you are using libraries.

If you want to understand what is actually happening on the machine, I do not think it is the best choice. C would be much better.

Re:Why I love Rust by pcwalton on Friday January 08, 2016 @11:37AM (#10866092)
> I think that Rust simplifies some things that you must do yourself in C++, and learning how to do them is valuable.

Given that you didn't answer the question, I think it's pretty clear at this point that you haven't used Rust. Rust is a low-level language with low-level control over memory and resources.

Re:Why I love Rust by curun1r on Friday January 08, 2016 @07:52PM (#10869474)
Speaking about C, since I never went too deep into C++.

The original assertion was:

> ...gives a developer more insight into the actual machine...

For better or worse, Rust feels like a reference is a proper abstraction over a memory location whereas C drives home that it really is just a number. Perhaps I don't know Rust well enough but, without unsafe, I'm not sure how I would refer to an arbitrary memory location or use pointer arithmetic to access memory locations relative to a known memory location in Rust. Vector indexes in Rust appear to be more than just syntax sugar for addition whereas C allows both array[2] and 2[array]. And I know that Rust will prevent me from accessing memory that's already been freed since it's one of the selling points of the language.

Now you can argue that Rust is mostly saving you from unpleasant consequences, and you'd be right. But the fact that C forces you to understand those unpleasant consequences teaches you something about the nature of the underlying machine. C makes you realize just how much of a "wild west" situation exists at that level. It would be very easy for someone to learn Rust without being confronted with that fact.

Re:Why I love Rust by hellofunk on Friday January 08, 2016 @02:36PM (#10867577)
I certainly don't know Rust as well as C++. Some other fellows in this thread provided some features in C++ that you can't learn about in Rust, fyi.
Re:Why I love Rust by pcwalton on Friday January 08, 2016 @02:50PM (#10867670)
> Some other fellows in this thread provided some features in C++ that you can't learn about in Rust, fyi.

Variadic generics and template templates are hardly interesting compared to concepts, pattern matching, and lifetimes. I use those every day in Rust, they simply don't exist in C++, and with the exception of lifetimes plenty of other languages have them too, so they're broadly useful to know. Variadic generics and template templates, on the other hand, are useful for a small subset of advanced library authors who have been programming in C++ for years.

Re:Why I love Rust by cjfont on Friday January 08, 2016 @07:42AM (#10864443)
If my understanding is correct, you can use any of those C++ libraries from Rust as well.
Re:Why I love Rust by kibwen on Friday January 08, 2016 @08:01AM (#10864525)
If those C++ libraries expose a C API, then yes.
Re:Why I love Rust by fiedzia on Friday January 08, 2016 @09:56AM (#10865238)
Well, it may teach you why its a good idea to throw away old features every couple of decades :-)
Re:Why I love Rust by neppo on Friday January 08, 2016 @05:55AM (#10864071)
OPs asked which language to learn from a career perspective, so C++ is good advice in that respect
Re:Why I love Rust by nickpsecurity on Friday January 08, 2016 @10:14AM (#10865386)
You must say the same thing about COBOL in other threads. Demand for it remains high with people getting paid a premium in some areas for the shortage. Something like a billion lines of it out there. Microfocus is probably hiring, too.

So, anyone following your argument should skip C++ and learn COBOL because COBOL is easier to learn, in widespread use, and has jobs available.

Re:Why I love Rust by hellofunk on Friday January 08, 2016 @11:00AM (#10865773)
Interesting point. I was curious about this, and turned to Wikipedia:

>In 2006 and 2012, Computerworld surveys found that over 60% of organizations used COBOL (more than C++ and Visual Basic .NET) and that for half of those, COBOL was used for the majority of their internal software. 36% of managers said they planned to migrate from COBOL, and 25% said they would like to if it was cheaper. Instead, some businesses have migrated their systems from expensive mainframes to cheaper, more modern systems, while maintaining their COBOL programs.

Re:Why I love Rust by nickpsecurity on Friday January 08, 2016 @11:31AM (#10866033)
It was an extremely, easy-to-use language that even laypeople could write business logic in. Similar to how BASIC got so many people started. Except, Fortune 500 companies were writing all their backend stuff in COBOL on mainframes from the 60's onward. Needless to say, there's a lot of it around dependent on existing libraries, interfaces, language variants, compilers, etc. Porting it is huge risk. So, they just maintain and extend it.

Main vendor even has it on Visual Studio: http://www.microfocus.com/solutions/cobol/index.aspx

The job is boring, predictable, and 9-5-ish at most places. Exactly what some types of people are looking for. They figure they can play with the fun stuff at home. One person even jokingly made a web framework for it: COBOL on Cogs. So, yeah, I throw COBOL at anyone using the "use language X for users or jobs" argument to see how they react to what they're actually arguing.

Interesting that you at least looked it up and didn't go into denial mode. I'm impressed. ;)

Re:Why I love Rust by shin_lao on Friday January 08, 2016 @04:33AM (#10863835)
Not really. From a carreer perspective you are 100% certain that there will be a lot of demand for C++ in 5 years (since the whole IT infrastructure is written either in C or in C++), whereas for Rust you are taking a huge bet.
Re:Why I love Rust by seren on Friday January 08, 2016 @05:41AM (#10864034)
Maybe my perspective is biased because I work in a very conservative industry, but a large part of C++ jobs in the next 5 years will likely be about maintenance/evolution of massive legacy C++98/C++03 applications. And you won't likely use a lot of C++14 or C++17, while on the other hand the rare Rust project might be a bit more exciting. But if you're primary motivation to learn a new language is to get a job, Cpp is surely a safer bet.
Re:Why I love Rust by pcwalton on Friday January 08, 2016 @12:34PM (#10866590)
> a large part of C++ jobs in the next 5 years will likely be about maintenance/evolution of massive legacy C++98/C++03 applications

This is exactly right, and it's been true for many years now. That your old codebase is written in C++ is a totally legitimate reason to use C++.

Re:Why I love Rust by hellofunk on Friday January 08, 2016 @05:05AM (#10863933)
Exactly, C++ has been around for a very long time, so much runs on it, depends on it, and it is not going anywhere any time in our lifetimes, I'm certain of that. That makes it a very valuable skill. You can always study the newer languages when interested in them (I find them all fascinating), but for a deep leg into the way the industry works at its core, I think knowing C++ gets you very far. Google touts Go a lot, but so much of Google's tools are actually C++ at heart (protobufs and Chrome for example), and Apple touts Swift and has its own frameworks in Objective-C and now Swift, but under the hood, so much of their toolkits and the language of Swift itself are implemented in C++; nearly all cross-platform games we know and love for a wide variety of devices and OS are C++ -- my point is that it is a crucial language and it does not hurt to understand it.
Re:Why I love Rust by jbandela1 on Friday January 08, 2016 @08:19AM (#10864615)
Rust lacks higher kind types which C++ has had in the form of template templates since 1998. Rust also lacks the equivalent of variadic templates. If you want to see where that is different take a look at generic tuple manipulation in C++11 vs Rust.
Re:Why I love Rust by pcwalton on Friday January 08, 2016 @12:42PM (#10866639)
And Rust has other features that no shipping version of C++ has, like full-featured pattern matching, lifetimes, and concepts. These are features you will use hugely more often than template templates and variadic generics.

But really, what's the point? The reasons you'd learn a low-level systems language are to learn how to manage memory and resources, to learn how to explicitly lay out data and to understand how to program without a runtime. Both Rust and C++ will teach you these.

Re:Why I love Rust by jbandela1 on Friday January 08, 2016 @09:19AM (#10864966)
I think that is a great answer. I actually see some parallels between the relationship of Rust/C++ to Scala/Java. Both basically use the backend of the established language and provide an 'improved' language on top of it. Scala uses the JVM, and Rust uses LLVM.

What is interesting is that with the release of Java 8, a lot of Scala early adopters and cutting back their investment in Scala in favor of Java (for exampled LinkedIn). This is despite the fact that Scala is widely used in production, has a killer app in Spark, and allows pretty seamless use of the Java library.

Now compare this to Rust. Rust also provides an 'improved' language in the same space as C++ utilizing LLVM. However, what is interesting is the nature of the improvements. The biggest feature of Rust is the memory safety. However, the memory safety is not a productivity improvement as more of a safety improvement. Unlike garbage collection where you just do not have to think about memory allocation issues, Rust forces you to think about ownership and mutability. That same exact thinking will allow you to pretty much get the same memory safety in C++ using unique_ptr and shared_ptr and const. The difference is that the compiler makes you think about it in Rust. Much like Scala inspired the adoption of features for Java, you can see C++ adopting pretty much the borrow checker as a tool - see Herb Sutter's talk at CppCon 2015 - https://www.youtube.com/watch?v=hEx5DNLWGgA .

As the experience with Scala shows, the adopted features of the established language do not have to perfectly match the 'improved' language to convince people to migrate back to the established language. The adopted features just have to be in the ballpark. I think the new C++ tooling will be in the ballpark in much the same way that Java 8 is in the same ballpark as Scala and remove much of the impetus for moving to Rust from C++.

In addition, Rust is not as well positioned as Scala. Scala is actually deployed in production and has a killer application. Rust has no major production deployments of which I am aware and no killer application (the equivalent of Spark). In addition, while Rust can interface with C libraries, Rust cannot interface with C++ libraries unlike Scala which can interoperate with the Java standard library.

Rust has some brilliant aspects just like Scala has some brilliant aspects. However, C++ (like Java) is not sitting still but has been incorporating the best ideas. In addition, when people choose a system language, they are inherently conservative because the system they are creating will typically be long lived and mission critical. If you are writing something that you hope will power your company for the next 20 years, do you want to go with a language created and driven by Mozilla with no major use in production, or with the language that powers Google, Microsoft, Apple, and Facebook?

Here is what I recommend. Learn C++11/14/17. Learn Haskell to really open your mind to what is possible. Learn Rust to learn about the borrow checker. Then apply what you have learned to make yourself a better C++ programmer. Some of the best, most insightful C++ programmers I know are people who are actually well-versed in other languages, especially functional programming languages.

Re:Why I love Rust by danieldk on Friday January 08, 2016 @09:45AM (#10865151)
I think the new C++ tooling will be in the ballpark in much the same way that Java 8 is in the same ballpark as Scala and remove much of the impetus for moving to Rust from C++.

I think that you extrapolate from an incorrect analogy. Java is a relatively simple language (except the mess introduced by generics through type erasure), that is mostly understood by regular practitioners. Java suffered far more from the lack of modern language features than technical debt. Consequently, it benefitted from language extensions tried first in Pizza/Scala, etc.

C++, on the other hand, is a very complex language as a result of inheriting C, the lack of deprecation of misfeatures for compatibility, and perhaps questionable design choices. C++ suffers not so much the lack of language features (though support for real algebraic data types and modules would be nice), but from complexity. Complexity of the language can only be reduced by breaking compatibility.

Re:Why I love Rust by fiedzia on Friday January 08, 2016 @10:07AM (#10865328)
"However, the memory safety is not a productivity improvement as more of a safety improvement."

I disagree. It frees you from chasing safety bugs and allows to invest more time in the features and that's clearly productivity win. For example rust does not suffer from compiler bugs as much as compilers written in C/C++ used to. Chrome and firefox developers spend a lot of time fixing buffer overflows and are likely to do this for many years to come. They certainly could do something more productive for everyone's benefit.

Re:Why I love Rust by pcwalton on Friday January 08, 2016 @11:46AM (#10866180)
> you can see C++ adopting pretty much the borrow checker as a tool - see Herb Sutter's talk at CppCon 2015 - https://www.youtube.com/watch?v=hEx5DNLWGgA .

I have a lot of questions about this tool, both in terms of soundness/expressivity (how do you deal with shared_ptr and similar things if your goal is to statically guarantee no-alias on function entry) and in terms of practicality (the massive subsetting it requires basically makes ISO Core C++ an entirely new language).

Also, Herb's claims about the ISO Core C++ lifetime profile requiring fewer annotations than Rust were incorrect.

I gave basically this exact answer last time you posted a variant of this same comment on the last Rust thread.

Re:Why I love Rust by kod on Friday January 08, 2016 @11:49AM (#10866202)
Anyone who's actually used Rust, C++, Scala, and Java knows that Rust and Scala involve considerably less suffering than their counterparts. The "adopted features" don't change the fundamental problems.

Java 8 lambdas are fundamentally broken due to checked exceptions, and the likelihood that checked exceptions are going to be removed from the language is essentially nil.

Likewise, Rust error messages are already better than C++ compiler error messages, and the nature of C++ template expansion makes that unlikely to change.

Learn what you want to learn... not what large companies have decided to adopt (or not) based on a number of factors that have nothing to do with the quality of the language or its educational value.

Re:Why I love Rust by steveklabnik on Friday January 08, 2016 @09:40AM (#10865119)

  > you can see C++ adopting pretty much the borrow checker as a tool
This may be because I'm too close to it, but the Core Guidelines are similar in ways, but also very different. Preventing data races is an explicit non-goal, for example, whereas in some ways, it's the focus of the borrow checker.

  > Rust has no major production deployments of which I am aware
Dropbox is the latest production user, as of last month. And it's serious production usage: how the bytes get stored on disk, basically the core of the whole business.
Re:Why I love Rust by nickpsecurity on Friday January 08, 2016 @10:26AM (#10865479)
I'd really like to know how well that works out at Dropbox. How honest and public do you think they'd be if major data losses resulted from Rust crapping out on them? I'm not sure about them but lots of businesses keep such things on the DL.

I think it's a risky move. I'd have first deployed existing, native code along with Rust in parallel using the data splitting technique so some is saved with original and some with Rust. Any compiler or library related issues on Rust side would be caught without data loss. I wonder if they did this in alpha stage and how long that lasted.

I mean, I love seeing Rust in production and some success stories would be great. It's just... wow, that's pretty mission critical for what I gather is still a beta-phase tool. I'd be testing on the middle or front-end layers first given they're usually stateless(ish).

Re:Why I love Rust by pcwalton on Friday January 08, 2016 @11:48AM (#10866198)
> I think it's a risky move.

> It's just... wow, that's pretty mission critical for what I gather is still a beta-phase tool.

I think this is very '90s thinking. Extreme "if it's not C++, you can't deploy it!" conservatism about programming languages hasn't been true for well over a decade. Paul Graham has written some nice essays about this very phenomenon.

Also, Rust is not "a beta-phase tool".

New languages are much easier to deploy since the PL Renaissance. There are a few holdout industries that still stick with C++ no matter what, such as games, but they'll come around eventually. :)

Re:Why I love Rust by nickpsecurity on Friday January 08, 2016 @11:58AM (#10866288)
You've been in discussions on this forum where I slam both C and C++. I'm clearly against it unless I absolutely have to use it due to its issues. That's why your strawman is more amusing than most. My actual argument was that new tools are usually unstable in terms of features, implementation bugs, and (with compilers) performance. So, default recommendation for mission-critical apps are mature tools whose strengths and weaknesses are well-understood so pro's can use them robustly.

Back to beta-phase claim, you're saying the core features and compiler of Rust are no longer in development or testing? Totally stable now with only extensions, library features, and optimizations being added? If so, that's good news and I'll drop that claim in the future. Otherwise, it's in the beta phase. Another hint would be existence of any bugs with core functionality in your compiler or libraries.

Again, though, if the spec and core functionality are frozen with all bugs fixed then I won't call it beta. Is it there yet?

Re:Why I love Rust by pcwalton on Friday January 08, 2016 @12:32PM (#10866577)
Yes, 1.0 is stable and the language will not change in backwards incompatible ways. It's been that way for months (google "rust stability deliverable").

"All bugs fixed" rules out every language in existence except CompCert, so I don't think that's a very interesting metric.

Re:Why I love Rust by nickpsecurity on Friday January 08, 2016 @01:16PM (#10866913)
Good to know on stability part. Far as bugs fixed, it's more on the lines of day-to-day use of the language in common scenarios. Are people getting unnecessary troubles out of the compiler? Typically don't for most languages as they work out most of them in common idioms and library functions in first, few years. If they're serious rather than 1-3 people's hobby, that is.

I certainly won't expect it to be bug free. Nice comeback with CompCert, though. ;)

Re:Why I love Rust by fiedzia on Friday January 08, 2016 @02:36PM (#10867578)
I've seen rust compiler bug once and that was long before 1.0. The only issue now is that some important API's are not yet declared stable (RFC still being open), so many 3rd-party libraries target nightly and won't work in stable. This is however matter or 1 or 2 releases, and proves that rust developers take this matter seriously and don't wont to stabilize anything they aren't 100% sure. For all practical purposes rust is usable now, and more and more people are using it - certainly more then 3. Generally looking at rust projects on github, most of issues are feature requests. I don't see issues with crashes or panics, while I know plenty for similar projects written in C, at least in their early days.
Re:Why I love Rust by nickpsecurity on Friday January 08, 2016 @04:38PM (#10868499)
Thanks for the detailed assessment. Sounds like a high quality, Beta to me. I also like the good things I keep hearing about the quality of libraries, etc.
Re:Why I love Rust by kibwen on Saturday January 09, 2016 @06:56AM (#10870952)

  > I'd have first deployed existing, native code along with 
  > Rust in parallel using the data splitting technique so 
  > some is saved with original and some with Rust.
Yes, this is how Dropbox tests all of their features, and they did this with their new Rust-based storage engine as well. This tool has been in development for over a year by now and has seen extensive multi-stage testing (at first handling only a few terabytes of data, then "just" petabytes, and now exabytes).
Re:Why I love Rust by nickpsecurity on Monday January 11, 2016 @03:21PM (#10883146)
I was expecting they probably did given what's on the line. Re-reading it, I realize it probably didn't come off that way. Gotta work on that.

Thanks for the confirmation, though. I do look forward to reading the experience report. Hoping they include data on all key attributes vs prior language: productivity, debugging time comparison, CPU use, memory use, integration issues, and any changes in defect rates. Community evaluating Rust needs that data for something at this level.

Re:Why I love Rust by steveklabnik on Friday January 08, 2016 @10:38AM (#10865577)
The project lead already said on Reddit that if Dropbox loses data, it's now Rust's fault, so... :)

The project was a whole team of engineers working for almost a year, with extensive testing. At least, that's what I've heard. So like, I think they did exactly what you said, it's just that it's ready by now.

Re:Why I love Rust by nickpsecurity on Friday January 08, 2016 @11:26AM (#10865998)
Oh shit! That's one hell of an endorsement [in the making]. I bet the excitement and suspense are thick in the office, eh? Hope it works out for adoption reasons.
Re:Why I love Rust by steveklabnik on Friday January 08, 2016 @12:48PM (#10866685)
Re:Why I love Rust by nickpsecurity on Friday January 08, 2016 @01:35PM (#10867076)
I appreciate that. It has some good details. Gotta leave to get some work done but I'll take the time to drop you a compliment related to this:

"Edit: also worth adding that he Rust core team has been amazingly friendly and helpful. We've had several meetings with them where they came to our office and basically said "how's it going? what do you need? open up your laptop and show us your biggest problem." The project is under very good management."

When Rust was being developed, the two languages that got me most excited as next-gen, systems tech were Julia mainly and Nim somewhat. They had a great choice of features balancing all sorts of attributes as PL's that might get easy adoption as C++ alternatives. Thing is, many blog posts reported their communities and dev teams were downright vicious on everything from questions to compiler bugs (wtf!?). That made it a no-go as there's an upper-bound on how good those projects can get building on such a creaky, hostile foundation.

That leaves Rust as my default recommendation for new, non-critical projects in this space. Like Dropbox employee, what I've noticed is the two of you on Rust teams here are unusually helpful and respectful compared to many in PL communities defending their work. Even pcwalton when he's clearly less than happy with my comments. ;)

The combination of brilliant design and seemingly (from my little exposure) excellent community is why I promote Rust. So, keep up the great work all of you! :)

Re:Why I love Rust by steveklabnik on Friday January 08, 2016 @01:37PM (#10867096)
Thanks so much. :)