3 ms·
What aspect is steep? From the code I've seen, Rust is intuitive when coming from the classical languages like Java, C or JS. It's not lisp or Haskell. To cla
by nefitty 5y ago
What aspect is steep?
From the code I've seen, Rust is intuitive when coming from the classical languages like Java, C or JS. It's not lisp or Haskell.
To clarify, I don't intend to come off dismissive. I'm genuinely curious what the scary parts are so I can better plan my own studies.
- sieabahlpark 5y ago
- wiz21c 5y agoI personnaly find the ownership thing really hard to get. That's the thing that protexts you from screwing memory in parallel code but the thing is you have to use it even in non parallel code. The other thing is that it's a set of rule which mixes with the type system, so at the beginning, I had hard times understanding if I had issues with my types or with the ownership (eventhough, I know, ownership issues are reported as such by the compiler). So in the end, you have to think about memory safety much more deeply. I get that my code really feels right once it's written with ownership principles but somehow, it makes Rust hard to start with. Now, this ownership part is something really new to me (I have ASM,C++,Python,Java real life experience), it makes me think better about about my programs. So it's a tough but fruitful experience.
- woile 5y agoThe borrow checker and lifetimes have been my pain points. Also understanding Some and Result, which after practicing I understood them, and now they are ok. They were foreign concepts to me. I still struggle with lifetimes, but I do understand them better.
- Measter 5y agoThe most common issues are with ownership, lifetimes, and the borrow checker. If the person is an experienced C or C++ programmer they'll probably have an easier time as you need some understanding of ownership and lifetimes to correctly use pointer-likes in those languages. The most likely issue here is that their mental model of ownership and lifetimes does not exactly match the borrow checker's. If they're coming from a language such as C# or Python, where you don't need to deal with these to anywhere near the same extent, suddenly being forced to reason about it just to pass the compiler can be bit of a hurdle.