Hacker News new | past | comments | ask | show | jobs | submit login

> after all, variables are just references

That's the whole point of Rust, that they are not that. They are named, sized memory slots that values can be moved into or moved out of.

> I have definitely seen people struggle to wrap their head around ...

The struggle comes from being forced to use recursion where it doesn't make things easier to express but harder. Then they remember it all compiles down to machine code that just uses iteration fueled by bare metal equivalent of goto-s and the struggle feels pointless.

Imagine somebody took away your stack so when you want to do recursion, you'd be forced to roll your own stack every time. You'd struggle too.




Consider applying for YC's W25 batch! Applications are open till Nov 12.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: