A couple more earlier threads if you want to deep dive on the higher-ranked stuff
- Generic function failing to satisfy "any" lifetime on argument
- Rust Quiz 5: when will higher-ranked closure type be yielded?
But the boldtype-in-textbook summary is still
-
&T
is not a (single, concrete) type [1] - Generic type parameters must resolve to a single, concrete type
And the small textbook-infobox-example is
-
fn(&String) -> &String
[2] does not satify a<I, O> Fn(&I) -> O
[3] bound- Because
O
would have to match&String
but that's not a type
- Because