blob: 8210d8a4c48f9e04c77c0f6d54b4dcb900e5dba8 (
plain)
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
|
error: types that do not implement `Drop` can still have drop glue, consider instead using `std::mem::needs_drop` to detect whether a type is trivially dropped
--> $DIR/dyn-drop.rs:2:19
|
LL | fn foo(_: Box<dyn Drop>) {}
| ^^^^
|
note: the lint level is defined here
--> $DIR/dyn-drop.rs:1:9
|
LL | #![deny(dyn_drop)]
| ^^^^^^^^
error: types that do not implement `Drop` can still have drop glue, consider instead using `std::mem::needs_drop` to detect whether a type is trivially dropped
--> $DIR/dyn-drop.rs:3:16
|
LL | fn bar(_: &dyn Drop) {}
| ^^^^
error: types that do not implement `Drop` can still have drop glue, consider instead using `std::mem::needs_drop` to detect whether a type is trivially dropped
--> $DIR/dyn-drop.rs:4:20
|
LL | fn baz(_: *mut dyn Drop) {}
| ^^^^
error: types that do not implement `Drop` can still have drop glue, consider instead using `std::mem::needs_drop` to detect whether a type is trivially dropped
--> $DIR/dyn-drop.rs:6:15
|
LL | _x: Box<dyn Drop>
| ^^^^
error: types that do not implement `Drop` can still have drop glue, consider instead using `std::mem::needs_drop` to detect whether a type is trivially dropped
--> $DIR/dyn-drop.rs:13:16
|
LL | type T = dyn Drop;
| ^^^^
error: aborting due to 5 previous errors
|