O'Reilly logo
  • Ivan Zderadicka thinks this is interesting:

Whether the semantics of the closure is move or borrow does not really matter at that point.


Cover of Mastering Rust


This is not exactly true I think - as we are returning the String, then outside_string has to move into closure - so closure is moving String aways into the closure.