top | item 38852437

(no title)

Dinux | 2 years ago

We have switched to Rust about 4 years back for most of our robotics and embedded control systems. I has been a blessing to move away from C/C++ after 10 years. Sure Rust has its problems and issues, especially when it comes to async and concurrency. Yes it has a steep learning curve, yes the compiler gets in the way often but the number of _actual_ bugs (not design flaws) is probably less than 10 over 4 years. Every time I work on a C/C++ i'm painfully reminded how easy it is to shoot yourself in the foot. I hope coreutils and Rust in the kernel will eventually become the default

discuss

order

PartiallyTyped|2 years ago

I genuinely can't get enough of rust tbh. It "just" works. Don't get me wrong, a few things could be better, e.g. compile times, but it's so much easier to work with.

klabb3|2 years ago

Please include the domain you’re working in and what you’re comparing against when making value statements like this. It can be helpful for others and the debate at large.

thesnide|2 years ago

i wonder how much of that is due to rust being too young to have myriads of dubious code to copy from.

Perl is even more memory safe than Rust, but the amount of crappy code is overwhelming...

steveklabnik|2 years ago

That's the thing about a compiler enforcing rules: you can't even get some kinds of dubious code to compile, so therefore, it will never meaningfully be copied.

Of course, that doesn't mean that all bugs are prevented, or that Rust code has no bugs, or that you can't write bad Rust code. But in the context of robotics and embedded control systems, Rust solves a lot of those "bad code" issues at compile time. And you're not using Perl in that context regardless.