Ask HN: Why should I learn Rust?

9 points by jdthedisciple ↗ HN
What would be a compelling reason to learn Rust for someone with a strong C# and MS Windows-oriented development background?

And what would be a great introductory Rust project for me to immediately appreciate and understand its benefits over other programming languages?

11 comments

[ 3.0 ms ] story [ 38.5 ms ] thread
Why do you feel like you should learn Rust?
(comment deleted)
As someone who has dived into Rust over the past few months, the two main reasons for employing it are: A) Bleeding edge performance (Shares the same problem space as C/C++, zero cost abstractions etc.) B) Memory safety (Giving it a rather unique flavour among systems languages - distinguishing it from the above two)

If you primarily work in C#, the latter won't be a problem you will be looking to solve anyway. I would say if the former intrigues you then Rust would be a great place to start.

It will make you much better at C#. Not to mention these languages share key similarities for you to appreciate the new ideas Rust brings in areas they don’t.
What new ideas does Rust bring, other than the borrow checker, which is useless in GC languages?
Have you ever used either C# (in an advanced way) or Rust? If not, which languages are you comfortable with?
I’m not sure how that’s relevant to my question.
My reason is, Rust has excellent interop with Python. That's a nice combo: fast and "hard" stuff in Rust, Python for scripting with it (which I do a lot of).

C++ ticks similar boxes, but I dislike it more than Rust :)

Are you looking to do anything that would benefit from it? AIUI, C# is a perfectly good language, especially in the Microsoft ecosystem. Don't get me wrong, broadening your horizons is good, but I would hesitate to learn rust specifically unless you really need to do something low level (whether because you're getting close to hardware, need no GC, need very precise memory control, other performance reasons...), target a platform that rust works on and C# doesn't, or want to use a library that's available in rust, isn't available in C#, and can't be surfaced to C# with minimal FFI wrapping.