Live data from Hacker News

Stop Whining about Rust Hype – A Pro-Rust Rant

thenewwazoo.github.io

1–10 of 71 posts

Re: Stop Whining about Rust Hype – A Pro-Rust Rant

#2
The Rust zealots I've noticed tend to have just very recently encountered the language. The developers who use it in production systems and in non-trivial applications tend to have a more mellow opinion lacking hype or whatever.

I use it during the work week and it solves a lot of problems and the ecosystem is maturing very quickly. Serde is by far the biggest boon of the language. It is truly state of the art as far as serialisation goes. I also agree with the writer about it not being hard. It's hard in the same way Erlang is hard, it just doesn't operate the way C-like languages conventionally do, though there are some similarities. The borrow checker is pretty easy to wrap your head around once you program more with it.

Overall its a good language. Not perfect, and I'm sure in the future we'll see some better languages, but for what it presents, it's as good of a tool as you'll get in some domains.

Re: Stop Whining about Rust Hype – A Pro-Rust Rant

#3
The problem occurs when I arrive on a landing page for a project re-invented in Rust that advertises not encountering double frees as a feature of the project. I notice the project is nothing more than a build tool for web development, and I just shake my head.

Re: Stop Whining about Rust Hype – A Pro-Rust Rant

#4

The Rust zealots I've noticed tend to have just very recently encountered the language. The developers who use it in production systems and in non-trivial applications tend to have a more mellow opinion lacking hype or whatever. I use it during the work week and it solves a lot of problems and the ecosystem is maturing very quickly. Serde is by far the biggest boon of the language. It is truly state of the art as far…

Personally, it's less "Rust is great" more "We are seeking to address performance bottlenecks in security sensitive, uncontrolled inputs, please don't make me go back to C".

Re: Stop Whining about Rust Hype – A Pro-Rust Rant

#5
I've dabbled in rust and it's been good but I've never progressed further than just modifying existing codebases.

I've yet to find a good toolkit/framework that helps me build web apps. I stick to JavaScript merely because it's a language that allows me to do most of what I want, in a tolerable way, in most situations, on both the client and server.

But, I know the problems with it. And there are a lot.

Is there a toolkit for building web apps that has the ergonomics of something like Svelte? Or, at least is a toolkit that radically simplifies building things in the client with wasm?

Until I find that, I'm just going to stick with JavaScript, only because it's more important for me to ship quick prototypes than build something perfect before I know what that is.

Re: Stop Whining about Rust Hype – A Pro-Rust Rant

#6
I'm pretty in the dark about [new thing]. I don't have skills in it and really don't grok it. And even though it seldom gets mentioned, my insecurity about that gap in my knowledge -- that thing that makes my existing knowledge a little bit obsolete -- makes me laser focused on those instances where it does appear (Baader-Meinhof phenomenon of sorts): If one in a hundred posts mentions [new thing], I'll throw my hands up and complain about how these hipsters are trying to push this stuff down my throat at every venue. Maybe I'll no true scotsman in a futile effort to try to coerce people against talking about it, for instance by claiming that real pros don't actually talk about it at all, Fight Club style.

This has played out over, and over, and over again. Blockchain, NoSQL, JavaScript, Angular, "web3", Android, iOS, Swift, K8s, and on and on. Legitimate criticism gets drown out by people just fearful that something might take hold and then they're going to have to change how they do things or learn something new.

Eh.

Re: Stop Whining about Rust Hype – A Pro-Rust Rant

#7
> Rust is “hard”. (It’s not, by the way. It’s not hard. It’s truly not.)

As someone who likes Rust, it takes days or weeks to wrap your head around the borrow checker, and "spaghetti object graph" code patterns in other languages don't transfer well to Rust (Cell is more awkward to use than C++ int, and RefCell introduces runtime panics). I've had the misfortune of dealing with code written in unsound unsafe Rust which freely converts aliased raw pointers into &mut, even when they likely conflict with other & or &mut. I still don't know how to rewrite it in safe Rust.

Rust is built around making mutable multiple ownership awkward. This is fine (and often results in more understandable code) when you're working in single-ownership code conceived and built around Rust, but when you're using something like gtk-rs (which binds to a C framework built around reference counting and cyclic parent pointers), Rust makes mutating shared state awkward (adding extra state alongside GTK widgets requires RefCell or similar), and reference-counted callbacks awkward (the clone! macro breaks rustfmt).

> Nobody thinks you’re smarter or better because you can remember all the pitfalls.

Oh, I know some people who think that way. Personally I think Rust teaches you the same things as C++ code (reasoning about state, knowing what parts of your code reference an object, knowing when to free an object).

> Soon your solution won’t be faster to market, and will be more expensive to maintain to boot. And someone’s going to eat your lunch while you complain.

There's no Rust GUI framework as comprehensive and mature as Qt. (Then again, there's no C++ GUI framework as clean, usable, and stable as Qt should've been. And people are moving to web UIs.) And some (not all) Rust libraries are amateurish from people who don't know what they're doing; for example, https://lib.rs/crates/samplerate allocates on every conversion (which isn't safe for real-time audio generation) rather than writing into a preallocated &mut buffer. https://docs.rs/hound/latest/hound/ is a WAV file reader which branches on every sample (IDK if it gets optimized out), rather than performing error checking at file open time and bounds checking once per block, which feels bizarre to me.

Re. "An ability to compensate for the shitty state of technology" that exists today isn’t some kind of a competitive “moat”.", writing your own bindings to C code, or performing unsafe C calls directly, instead of using the ergonomic libraries which don't work properly, is compensating for shitty technology.

IMO this article comes pretty close to flamebait and trolling.

Re: Stop Whining about Rust Hype – A Pro-Rust Rant

#8
post #5

I've dabbled in rust and it's been good but I've never progressed further than just modifying existing codebases. I've yet to find a good toolkit/framework that helps me build web apps. I stick to JavaScript merely because it's a language that allows me to do most of what I want, in a tolerable way, in most situations, on both the client and server. But, I know the problems with it. And there are a lot. Is there a to…

> I've yet to find a good toolkit/framework that helps me build web apps.

Ironically, there's a sibling comment complaining about how so much of the Rust dev ecosystem is just people making "nothing more than build tools for web development". You can be sure that people are just whining when they can't even get their story straight.

Re: Stop Whining about Rust Hype – A Pro-Rust Rant

#10
post #3

The problem occurs when I arrive on a landing page for a project re-invented in Rust that advertises not encountering double frees as a feature of the project. I notice the project is nothing more than a build tool for web development, and I just shake my head.

Personally I tend to use C and C++ tools more often, and in that universe, being statically free of memory errors is an innovation. In the webdev world, I suppose native speed and not having a large runtime or GC is Rust's primary innovation (though for batch jobs like build tools, a small Go-like runtime/GC isn't actually a negative compared to Rust, and I've never noticed GC pauses when I previously use the Micro editor in Golang).
Post reply on HN