I found myself in a situation where I wanted to create a mass impl for a library Error class of mine.
I wanted to have a From on anything that implemented Debug. (sure I’m being lazy, but it made sense)
The problem was that my error class also implemented Debug.
This created an ambiguity because the From trait has a mass impl of
impl<T> From<T> for T
Which obiously makes sense. Anything can come from itself.
But this created an ambiguity.
I’d like to be able to write something like
Impl <T:Debug - Self> From<T> for MyErr{
...
}
Or minus some other trait.or type.
Another option for disambiguity would be ranking.
just playing with thoughtts at the moment. currently I have a few specific impl for the errors I need.