/
syntax-trait-polarity.stderr
44 lines (37 loc) · 1.21 KB
/
syntax-trait-polarity.stderr
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
error: inherent impls cannot be negative
--> $DIR/syntax-trait-polarity.rs:7:6
|
LL | impl !TestType {}
| ^
error[E0198]: negative impls cannot be unsafe
--> $DIR/syntax-trait-polarity.rs:12:13
|
LL | unsafe impl !Send for TestType {}
| ------ ^^^^^
| |
| unsafe because of this
error: inherent impls cannot be negative
--> $DIR/syntax-trait-polarity.rs:19:9
|
LL | impl<T> !TestType2<T> {}
| ^
error[E0198]: negative impls cannot be unsafe
--> $DIR/syntax-trait-polarity.rs:22:16
|
LL | unsafe impl<T> !Send for TestType2<T> {}
| ------ ^^^^^
| |
| unsafe because of this
error[E0192]: negative impls are only allowed for auto traits (e.g., `Send` and `Sync`)
--> $DIR/syntax-trait-polarity.rs:14:1
|
LL | impl !TestTrait for TestType {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error[E0192]: negative impls are only allowed for auto traits (e.g., `Send` and `Sync`)
--> $DIR/syntax-trait-polarity.rs:24:1
|
LL | impl<T> !TestTrait for TestType2<T> {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: aborting due to 6 previous errors
Some errors have detailed explanations: E0192, E0198.
For more information about an error, try `rustc --explain E0192`.