Hacker News new | ask | show | jobs
by ncmncm 1652 days ago
Nothing sets off Rust fans quite like hinting it might still fizzle.

(Fizzling is a likely outcome for any new language, and does not suffer the mess of interpretation that "dying" carries.)

The thing is, there was a time when Ada had a lot more industry support and investment than Rust has today. OS kernels were coded in it. Aircraft and satellite instrumentation was coded in it, with billion-dollar contracts. Ada fizzled.

Erlang had rapidly growing support in the '90s. It had unique strengths. Erlang fizzled, too.

As hot as Rust is on HN, it could still fizzle in exactly the same way, for the same reasons. You might code something good in your work, but when you move on, will anybody be found to maintain it? People with Erlang skills today are most in demand to rewrite Erlang systems in something, anything not Erlang.

The rabid response and reflexive downvoting seen for anything even slightly critical of Rust betrays a level of insecurity that does not bode well for Rust.

For Rust to succeed, it probably needs at least a 10x improvement to compilation speed. That will probably require uncomfortable and difficult changes to the language and core libraries. Is there appetite for such changes among the faithful, who have come to terms with extremely slow builds already? To succeed, Rust needs to attract hundreds more for each current user. They have not accepted its weaknesses yet, and might never.

Rust needs to be easier to adopt. Rust is already as complicated to learn and use effectively as C++, but with nowhere near the level of industry support. Rust enthusiasts are little islands in the ocean; you have to go online to talk over design details, most places. It needs to not demand arcane, abstruse apparatus for ordinary things. (C++ has been good at sealing off difficult apparatus in easy-to-use libraries.)

When you think Rust must be really taking off already, consider that more people pick up C++ for the first time, in any week, than the total who are employed full time coding Rust. Rust really can still fizzle, as unpleasant as that is to consider. Vociferous advocacy is not what will save it. It needs much harder measures, that will appeal much more to people not now coding Rust than to those scattered few who already do. For now.

1 comments

> Rust is already as complicated to learn and use effectively as C++

I see a lot of claims to this effect but having tried to learn both I found Rust much easier. It's also safe by default, which C++ isn't. How exactly do you think it's equally complicated?

We all know that Rust is "safe by default". That is part of what makes it complicated.

Most of the complexity of C++ comes from its long history, with new features layered on old, extra junk you have to say to get the new stuff, and old stuff to stay clear of. E.g., constructors should be explicit, and lots of things should be const, and you have to call std::move() to pass a value that way, and implicit conversions can happen accidentally. But actually using it, sticking to the modern bits, doesn't depend on much in the way of new concepts. Writing libraries for general use depends on deep lore, but that doesn't leak out to users of the libraries, who just get libraries that can do more for them.

In Rust, you need to learn a whole new regime to do even basic things. And, you need to learn workarounds for what C++ does but Rust doesn't, yet. There are literally thousands of times as many people who can answer questions about C++ than about Rust, so mysteries are shallower.

> In Rust, you need to learn a whole new regime to do even basic things.

Sure, but the same can be said of any language that’s significantly different from C++ (OCaml, or Erlang for example). That doesn’t mean they’re as complicated.

Rust syntax and semantics are basically ML syntax with curly braces and semicolons on top. Having already learned OCaml by the time I picked up Rust, all I needed to internalize was the borrow checker, which is simpler to appease than it first appears.

> There are literally thousands of times as many people who can answer questions about C++ than about Rust, so mysteries are shallower.

Again, this is an argument about adoption more than about the intrinsic complexity of the language. I agree it’s harder to find answers, but that’s always going to be true when the languages you’re comparing to are C/C++/Python/Java/JavaScript.

> But actually using it, sticking to the modern bits, doesn't depend on much in the way of new concepts.

I disagree that smart pointers and move semantics aren’t new concepts. But more importantly this is basically an admission that C++ is vastly more complicated. It doesn’t really matter that there are subsets of C++ that are simpler, because to be able to understand code written by other people, and old code, you will need to understand these bits. The same is not true of Rust.

The overwhelming majority of what you need to learn to understand old code is what was built out of the old code. Language complexity there is a rounding error. So, the relevant complexity is what you need to understand to write new code.

Detailed comparisons will be meaningless. It suffices that they are comparable, of similar order. Somebody coming from Haskell or an ML will have a completely different experience than somebody coming from JS or Python.

Move semantics and smart pointers are about the same in C++ and Rust, so do not count in a comparison.

I learned Rust a few years ago, but cannot follow Rust code examples published today. It has become markedly more complex in a short time.

For Rust not to fizzle, literally thousands of programmers wholly unacquainted with it will need to adopt it for each current user. None of the former come bought into any of what current users have chosen to endure. To get those programmers on board, things will need to happen that most current users do not perceive as necessary, many of which they would absolutely revile, and many others they do not consider worth enough effort.

Overcoming resistance to necessary change from current users will be much, much harder than getting the new users on board after changes. Getting enough new users on board without those changes is probably impossible.

> I learned Rust a few years ago, but cannot follow Rust code examples published today. It has become markedly more complex in a short time.

Interesting. I suspect this is where our experiences differ the most, I started learning Rust around when it came out and have felt it only get simpler and more consistent over time. I do not see many major differences between Rust written now and Rust written then. The biggest one is async, which is definitely a big difference.