4 ms·
I agree with some of the points, but some of them are a bit weird. Like: creating a section called "Rust is unpredictable", because one library panicked? Anoth
by drogus 4y ago
I agree with some of the points, but some of them are a bit weird. Like: creating a section called "Rust is unpredictable", because one library panicked?
Another thing is with the out of bound reads. Sure, you can make an out of bound read, but I'm pretty sure most of the production projects use clippy that would error out on this and require you to use `v.get(0)` instead of `v[0]`.
- woodruffw 4y agoI read this as a relatively junior Rust programmer getting the lay of the land. I can certainly understand the "unpredictable" label from that perspective: there are a lot of people just learning Rust who might be "oversold" on what the language can and can't do, and are surprised when their programs fail hard rather than statically preventing all bugs (or, worse, silently doing the wrong thing). > Another thing is with the out of bound reads. Sure, you can make an out of bound read, but I'm pretty sure most of the production projects use clippy that would error out on this and require you to use `v.get(0)` instead of `v[0]`. To be precise: you can't cause an OOB read in safe Rust. You can write code that would read or write OOB, but Rust will always insert a panicking bounds check (unless it can prove statically that the operation is always in range).
- drogus 4y agoGood point about out of bounds read! Totally correct, what I meant is that you can panic when reading outside of array range, but my non-systems programming language background shows here :)
- drogus 4y ago> there are a lot of people just learning Rust who might be "oversold" on what the language can and can't do, and are surprised when their programs fail hard rather than statically preventing all bugs (or, worse, silently doing the wrong thing). Sure, that sounds like a good explanation. I guess I'm here too long to expect perfect stability from anything. That said, I still think that all things considered Rust ecosystem is one of the more reliable I've worked with. Both from the development and production experience. In the context of development I very rarely have any problems with installing or using libraries. Definitely much less frequently than in npm, rubygems or pip. In the context of production it's even better I think. Yes, occasionally you run into a problem, but most of the times systems written in Rust just work without virtually no crashes. The only big issue I ran into in the past was the Warp web framework having a memory related bug, which led to it using the entire available memory given enough traffic. It was an early version of the framework, though, so hardly something I would be very surprised about.