I found a way to write my generic (mostly with help of error messages from a compiler). I got this construction:
fn<T> ... where <T as std::ops::Div>::Output: Into<T> { ... }
Can someone explain me what as
here means? I have intuition of it (output type parameter for trait Div for T should have Into
implemented for T), but what is 'as' in this context?