You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Not sure if this has already been brought up or discussed elsewhere, and if so, I apologize in advance.
traitXxx{typeTarget;}traitYyy{}traitZzz{fndo_stuff(&self) -> i32;}structWww{}structUuu{}structVvv{}structQqq{}implXxxforVvv{typeTarget = Www;}//This is disallowed by the compiler/*impl Xxx for Vvv { type Target = Uuu; }*/impl<T>ZzzforTwhereT:Xxx<Target=Www>{fndo_stuff(&self) -> i32{1}}//Therefore this should be possible. The two sets here are disjoint //with no possibility of overlapimpl<T>ZzzforTwhereT:Xxx<Target=Uuu>{fndo_stuff(&self) -> i32{2}}fnmain(){}
Compiling playground v0.0.1 (file:///playground)
error[E0119]: conflicting implementations of trait `Zzz`:
--> src/main.rs:32:1
|
24 | impl<T> Zzz for T where T: Xxx<Target=Www> {
| ------------------------------------------ first implementation here
...
32 | impl<T> Zzz for T where T: Xxx<Target=Uuu> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation
error: aborting due to previous error
For more information about this error, try `rustc --explain E0119`.
error: Could not compile `playground`.
To learn more, run the command again with --verbose.
The text was updated successfully, but these errors were encountered:
Not sure if this has already been brought up or discussed elsewhere, and if so, I apologize in advance.
(Playground)
Errors:
The text was updated successfully, but these errors were encountered: