3 ms·
Well, the first two confusingly change two variables at once: the things that are the same (which I presume is what kimundi meant) are fn foo<S, T: MyTrait
by dbaupp 12y ago
Well, the first two confusingly change two variables at once: the things that are the same (which I presume is what kimundi meant) are
fn foo<S, T: MyTrait<S>>(elem: T) { ... }
fn foo<S, T>(elem: T) where T: MyTrait<S> { ... }
and
fn foo<S, T: MyTrait<Thing = S>>(elem: T) { ... }
fn foo<S, T>(elem: T) where T: MyTrait<Thing = S> { ... }