What are move semantics in Rust?
问题 In Rust, there are two possibilities to take a reference Borrow , i.e., take a reference but don\'t allow mutating the reference destination. The & operator borrows ownership from a value. Borrow mutably , i.e., take a reference to mutate the destination. The &mut operator mutably borrows ownership from a value. The Rust documentation about borrowing rules says: First, any borrow must last for a scope no greater than that of the owner. Second, you may have one or the other of these two kinds