This question already has answers here: Do mutable references have move semantics? (1 answer) Variable binding: moving a &mut or borrowing the referent?