]> git.proxmox.com Git - rustc.git/blob - src/test/ui/coherence/coherence-impls-sized.rs
New upstream version 1.41.1+dfsg1
[rustc.git] / src / test / ui / coherence / coherence-impls-sized.rs
1 #![feature(optin_builtin_traits)]
2
3 use std::marker::Copy;
4
5 enum TestE {
6 A
7 }
8
9 struct MyType;
10
11 struct NotSync;
12 impl !Sync for NotSync {}
13
14 impl Sized for TestE {}
15 //~^ ERROR E0322
16
17 impl Sized for MyType {}
18 //~^ ERROR E0322
19
20 impl Sized for (MyType, MyType) {}
21 //~^ ERROR E0322
22 //~| ERROR E0117
23
24 impl Sized for &'static NotSync {}
25 //~^ ERROR E0322
26
27 impl Sized for [MyType] {}
28 //~^ ERROR E0322
29 //~| ERROR E0117
30
31 impl Sized for &'static [NotSync] {}
32 //~^ ERROR E0322
33 //~| ERROR E0117
34
35 fn main() {
36 }