4 ms·
I work for one of the one of the companies that uses Rust in production (see https://www.rust-lang.org/friends.html https://www.rust-lang.org/friends.html for a
by ekidd 10y ago
I work for one of the one of the companies that uses Rust in production (see https://www.rust-lang.org/friends.html https://www.rust-lang.org/friends.html for a partial list). We're pretty happy with it.
I like Rust because it offers in an interesting combination of features:
1. Rust feels a bit like a good modern scripting language: It's doesn't segfault, the command-line tools are standard and mature, and it has excellent management of third-party libraries. You don't need to be constantly paranoid and vigilant to write correct code in Rust the way you need to be when working with C pointers, for example.
2. Rust feels a bit like C++: It's fast (when used correctly), it provides a "bare-metal" level of control, it doesn't require a GC, and it has generic types. Generic types are a mixed blessing: They're good for performance and correctness, but they can sometimes be a bit complex.
3. Rust feels a tiny bit like a functional language: Data is immutable by default, and you have a rich toolbox for building abstractions.
On the downside, Rust does have a learning curve. If you have solid experience with both C++ and a language like JavaScript or Ruby, plan on a week or two with Rust before you're comfortable. If you've never worked in any language with pointers, or if you've never worked in a language with anonymous functions, it might take longer.
Another Rust weakness is IDE support. Visual Studio Code and Emacs are both pretty reasonable, but if you're used to Java or C# IDEs with sophisticated refactoring support, that won't be mature in Rust until later this year.
I also find that with Rust, I spend a lot more time getting my code to compile, but once it does compile, it almost always works correctly on the first try. This can sometimes feel like "fighting with the compiler", but when you think about it, that's a lot better than "fighting with the debugger" or adding tons of printf statements everywhere. This "if it compiles it probably works" property also means that I can refactor aggressively and trust the results. But it still feels weird sometimes.
- jmcomets 10y agoYou're at a french company using Rust in production? Might I ask which one? ;)
- ekidd 10y agoSorry! My browser is set to French, so I pasted the wrong URL. Fixed. There's actually a surprisingly large French-speaking Rust community, which you can find on Mozilla IRC at #rust-fr. I work for Faraday in Vermont (http://www.faraday.io/ http://www.faraday.io/). We have, I think, 6 Rust applications. These include cage (http://cage.faraday.io/ http://cage.faraday.io/), which is an open source tool for developing complex, multi-"pod" Docker projects. We also use Rust for moving lots of data into and out of machine learning systems quickly, and we're going to be using for more data loading tasks soon.