]> git.proxmox.com Git - rustc.git/blame - 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
CommitLineData
c34b1796 1#![feature(optin_builtin_traits)]
223e47cc 2
c34b1796 3use std::marker::Copy;
1a4d82fc 4
c34b1796
AL
5enum TestE {
6 A
7}
223e47cc 8
c34b1796
AL
9struct MyType;
10
11struct NotSync;
12impl !Sync for NotSync {}
13
0731742a 14impl Sized for TestE {}
60c5eb7d 15//~^ ERROR E0322
0731742a
XL
16
17impl Sized for MyType {}
60c5eb7d 18//~^ ERROR E0322
0731742a
XL
19
20impl Sized for (MyType, MyType) {}
60c5eb7d
XL
21//~^ ERROR E0322
22//~| ERROR E0117
0731742a
XL
23
24impl Sized for &'static NotSync {}
60c5eb7d 25//~^ ERROR E0322
0731742a
XL
26
27impl Sized for [MyType] {}
60c5eb7d
XL
28//~^ ERROR E0322
29//~| ERROR E0117
0731742a
XL
30
31impl Sized for &'static [NotSync] {}
60c5eb7d
XL
32//~^ ERROR E0322
33//~| ERROR E0117
c34b1796
AL
34
35fn main() {
36}