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

So the only thing that is "moving" is the ownership of elements of a structure.

It seems "partial move" actually means "partial transfer".




> So the only thing that is "moving" is the ownership of elements of a structure.

Yup

In rust, you can move, copy or borrow a value.

Move - means that the responsibility of freeing the allocated memory is moving to someone else. Rust says the ownership has moved.

Copy - means that the full value is copied, and a copy is passed, thus now you have two instances of the value, and each can act independently.

Borrow - means that the access permissions to the value are temporarily transferred to something else, but will come back when done, and the responsibility of freeing the memory is still up to the owner (lender).

That's why it is called "partial move", cause it's using Rust's terminology. Transfer isn't in the Rust lexicon, so it wouldn't be as appropriate.




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

Search: