pub fn compose_two<A, B, C, G, F>(f: F, g: G) -> impl FnOnce(A) -> C
Expand description
Compose two functions into one.
Return f(g(x))
ยงArguments
f
- The givenFnOnce
.g
- The givenFnOnce
.
NOTE: Credit https://stackoverflow.com/questions/45786955/how-to-compose-functions-in-rust