Re:My favorite Rust function
by db48x on Saturday October 12, 2019 @07:49PM
(#21237174)
It won't compile, because the compiler keeps track of where you moved the value and notices that x now has no value. If you want the function to borrow the argument instead, make it take a reference, &x.
[ Parent
| on HN ]
There are no comments on this comment yet.