]> git.proxmox.com Git - rustc.git/blob - src/test/ui/drop-bounds/drop-bounds.stderr
New upstream version 1.66.0+dfsg1
[rustc.git] / src / test / ui / drop-bounds / drop-bounds.stderr
1 error: bounds on `T: Drop` are most likely incorrect, consider instead using `std::mem::needs_drop` to detect whether a type can be trivially dropped
2 --> $DIR/drop-bounds.rs:2:11
3 |
4 LL | fn foo<T: Drop>() {}
5 | ^^^^
6 |
7 note: the lint level is defined here
8 --> $DIR/drop-bounds.rs:1:9
9 |
10 LL | #![deny(drop_bounds)]
11 | ^^^^^^^^^^^
12
13 error: bounds on `U: Drop` are most likely incorrect, consider instead using `std::mem::needs_drop` to detect whether a type can be trivially dropped
14 --> $DIR/drop-bounds.rs:5:8
15 |
16 LL | U: Drop,
17 | ^^^^
18
19 error: bounds on `impl Drop: Drop` are most likely incorrect, consider instead using `std::mem::needs_drop` to detect whether a type can be trivially dropped
20 --> $DIR/drop-bounds.rs:8:17
21 |
22 LL | fn baz(_x: impl Drop) {}
23 | ^^^^
24
25 error: bounds on `T: Drop` are most likely incorrect, consider instead using `std::mem::needs_drop` to detect whether a type can be trivially dropped
26 --> $DIR/drop-bounds.rs:9:15
27 |
28 LL | struct Foo<T: Drop> {
29 | ^^^^
30
31 error: bounds on `U: Drop` are most likely incorrect, consider instead using `std::mem::needs_drop` to detect whether a type can be trivially dropped
32 --> $DIR/drop-bounds.rs:12:24
33 |
34 LL | struct Bar<U> where U: Drop {
35 | ^^^^
36
37 error: bounds on `Self: Drop` are most likely incorrect, consider instead using `std::mem::needs_drop` to detect whether a type can be trivially dropped
38 --> $DIR/drop-bounds.rs:15:12
39 |
40 LL | trait Baz: Drop {
41 | ^^^^
42
43 error: bounds on `T: Drop` are most likely incorrect, consider instead using `std::mem::needs_drop` to detect whether a type can be trivially dropped
44 --> $DIR/drop-bounds.rs:17:9
45 |
46 LL | impl<T: Drop> Baz for T {
47 | ^^^^
48
49 error: aborting due to 7 previous errors
50