October 2018
Beginner
180 pages
4h 48m
English
A higher-order function is a function that takes another function, or a closure, as a parameter. In Rust, there are three somewhat unusual traits that allow us to specify a function or closure as a parameter's trait bound: Fn, FnOnce, and FnMut.
The differences between these traits are defined by what kind of variable access they permit:
Read now
Unlock full access