DEV Community

Discussion on: Why Learn Rust?

 
stevepryde profile image
Steve Pryde

I tend to take the opposite approach and say that rust provides safety without needing to go for a full functional language. I think both functional languages and rust have similar concerns. I just much prefer the way Rust approaches it because I'm not forced into one paradigm (functional vs imperative).

I use functional programming techniques a lot but I never want to be limited to them. It's one paradigm. It's not the only one.

Memory safety is only a tiny part of why I like Rust. Mostly I like the correctness and safety aspects. I think it has a good balance of features from many mainstream sources.

Thread Thread
 
dmbaturin profile image
Daniil Baturin

If Rust works for you, then it works for you. The problem is, you don't know what else is in the store. And you wouldn't be worse off if you knew. ;)

OCaml definitely doesn't force you into the functional paradigm. It even has an OO system with type inference for objects.
Among ML descendants, there's also Swift that tries it best to pretend it's not a functional language to avoid scaring Objective-C users off.

I never regret learning Rust. I also don't use it in my current projects, though I may use if it in the future.