]> git.lizzy.rs Git - rust.git/blob - src/test/ui/coherence/coherence-overlap-trait-alias.rs
Merge commit 'ea199bacef07213dbe008841b89c450e3bf0c638' into rustfmt-sync
[rust.git] / src / test / ui / coherence / coherence-overlap-trait-alias.rs
1 #![feature(rustc_attrs)]
2 #![feature(trait_alias)]
3
4 trait A {}
5 trait B {}
6 trait AB = A + B;
7
8 impl A for u32 {}
9 impl B for u32 {}
10
11 trait C {}
12 #[rustc_strict_coherence]
13 impl<T: AB> C for T {}
14 #[rustc_strict_coherence]
15 impl C for u32 {}
16 //~^ ERROR
17 // FIXME it's giving an ungreat error but unsure if we care given that it's using an internal rustc
18 // attribute and an artificial code path for testing purposes
19
20 fn main() {}