]> git.lizzy.rs Git - rust.git/blob - src/test/ui/coherence/coherence-impls-sized.stderr
Rollup merge of #85766 - workingjubilee:file-options, r=yaahc
[rust.git] / src / test / ui / coherence / coherence-impls-sized.stderr
1 error[E0117]: only traits defined in the current crate can be implemented for arbitrary types
2   --> $DIR/coherence-impls-sized.rs:20:1
3    |
4 LL | impl Sized for (MyType, MyType) {}
5    | ^^^^^^^^^^^^^^^----------------
6    | |              |
7    | |              this is not defined in the current crate because tuples are always foreign
8    | impl doesn't use only types from inside the current crate
9    |
10    = note: define and implement a trait or new type instead
11
12 error[E0117]: only traits defined in the current crate can be implemented for arbitrary types
13   --> $DIR/coherence-impls-sized.rs:27:1
14    |
15 LL | impl Sized for [MyType] {}
16    | ^^^^^^^^^^^^^^^--------
17    | |              |
18    | |              this is not defined in the current crate because slices are always foreign
19    | impl doesn't use only types from inside the current crate
20    |
21    = note: define and implement a trait or new type instead
22
23 error[E0117]: only traits defined in the current crate can be implemented for arbitrary types
24   --> $DIR/coherence-impls-sized.rs:31:1
25    |
26 LL | impl Sized for &'static [NotSync] {}
27    | ^^^^^^^^^^^^^^^------------------
28    | |              |
29    | |              this is not defined in the current crate because slices are always foreign
30    | impl doesn't use only types from inside the current crate
31    |
32    = note: define and implement a trait or new type instead
33
34 error[E0322]: explicit impls for the `Sized` trait are not permitted
35   --> $DIR/coherence-impls-sized.rs:14:1
36    |
37 LL | impl Sized for TestE {}
38    | ^^^^^^^^^^^^^^^^^^^^ impl of 'Sized' not allowed
39
40 error[E0322]: explicit impls for the `Sized` trait are not permitted
41   --> $DIR/coherence-impls-sized.rs:17:1
42    |
43 LL | impl Sized for MyType {}
44    | ^^^^^^^^^^^^^^^^^^^^^ impl of 'Sized' not allowed
45
46 error[E0322]: explicit impls for the `Sized` trait are not permitted
47   --> $DIR/coherence-impls-sized.rs:20:1
48    |
49 LL | impl Sized for (MyType, MyType) {}
50    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ impl of 'Sized' not allowed
51
52 error[E0322]: explicit impls for the `Sized` trait are not permitted
53   --> $DIR/coherence-impls-sized.rs:24:1
54    |
55 LL | impl Sized for &'static NotSync {}
56    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ impl of 'Sized' not allowed
57
58 error[E0322]: explicit impls for the `Sized` trait are not permitted
59   --> $DIR/coherence-impls-sized.rs:27:1
60    |
61 LL | impl Sized for [MyType] {}
62    | ^^^^^^^^^^^^^^^^^^^^^^^ impl of 'Sized' not allowed
63
64 error[E0322]: explicit impls for the `Sized` trait are not permitted
65   --> $DIR/coherence-impls-sized.rs:31:1
66    |
67 LL | impl Sized for &'static [NotSync] {}
68    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ impl of 'Sized' not allowed
69
70 error: aborting due to 9 previous errors
71
72 Some errors have detailed explanations: E0117, E0322.
73 For more information about an error, try `rustc --explain E0117`.