9000 shaares
207 private links
207 private links
How to Choose
- If the closure only reads from the environment: Use Fn.
- If the closure needs to mutate the environment: Use FnMut.
- If the closure needs to consume ownership of values from the environment: Use FnOnce.