]> git.proxmox.com Git - rustc.git/blob - src/test/ui/coherence/coherence-tuple-conflict.rs
New upstream version 1.41.1+dfsg1
[rustc.git] / src / test / ui / coherence / coherence-tuple-conflict.rs
1 use std::fmt::Debug;
2 use std::default::Default;
3
4 // Test that a blank impl for all T conflicts with an impl for some
5 // specific T.
6
7 trait MyTrait {
8 fn get(&self) -> usize;
9 }
10
11 impl<T> MyTrait for (T,T) {
12 fn get(&self) -> usize { 0 }
13 }
14
15 impl<A,B> MyTrait for (A,B) {
16 //~^ ERROR E0119
17 fn get(&self) -> usize { self.dummy }
18 }
19
20 fn main() { }