complete part 10
[rust-101.git] / src / part05.rs
index b593360122a7ba8beb277a494f2e3eb48c555056..6d2d813144cdb8f239352bd9053a3c2c9c4d286d 100644 (file)
@@ -48,8 +48,10 @@ impl BigInt {
     }
 
     // We can convert any vector of digits into a number, by removing trailing zeros. The `mut`
-    // declaration for `v` here is just like the one in `let mut ...`, it says that we will locally
-    // change the vector `v`.
+    // declaration for `v` here is just like the one in `let mut ...`: We completely own `v`, but Rust
+    // still asks us to make our intention of modifying it explicit. This `mut` is *not* part of the
+    // type of `from_vec` - the caller has to give up ownership of `v` anyway, so they don't care anymore
+    // what you do to it.
     // 
     // **Exercise 05.1**: Implement this function.
     //