2022-04-24 12:08:23 +00:00
|
|
|
error: call to unsafe function `unsf` is unsafe and requires unsafe block (error E0133)
|
2021-05-24 10:55:01 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:12:5
|
2020-05-03 21:11:58 +00:00
|
|
|
|
|
|
|
|
LL | unsf();
|
2022-04-24 12:42:30 +00:00
|
|
|
| ^^^^^^ call to unsafe function
|
2020-05-03 21:11:58 +00:00
|
|
|
|
|
2022-09-18 15:55:36 +00:00
|
|
|
= note: consult the function's documentation for information on how to avoid undefined behavior
|
2020-05-03 21:11:58 +00:00
|
|
|
note: the lint level is defined here
|
2021-05-24 10:55:01 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:4:9
|
2020-05-03 21:11:58 +00:00
|
|
|
|
|
2020-05-21 21:53:12 +00:00
|
|
|
LL | #![deny(unsafe_op_in_unsafe_fn)]
|
2020-05-03 21:11:58 +00:00
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-05-21 21:53:12 +00:00
|
|
|
error: dereference of raw pointer is unsafe and requires unsafe block (error E0133)
|
2022-04-26 10:43:00 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:15:5
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
LL | *PTR;
|
|
|
|
| ^^^^ dereference of raw pointer
|
|
|
|
|
|
2021-05-02 21:55:22 +00:00
|
|
|
= note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
error: use of mutable static is unsafe and requires unsafe block (error E0133)
|
2022-04-26 10:43:00 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:17:5
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
LL | VOID = ();
|
2021-05-24 10:55:01 +00:00
|
|
|
| ^^^^ use of mutable static
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
= note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
|
|
|
|
|
2021-01-17 10:07:43 +00:00
|
|
|
error: unnecessary `unsafe` block
|
2022-04-26 10:43:00 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:20:5
|
2021-01-17 10:07:43 +00:00
|
|
|
|
|
|
|
|
LL | unsafe {}
|
|
|
|
| ^^^^^^ unnecessary `unsafe` block
|
|
|
|
|
|
|
|
|
note: the lint level is defined here
|
2021-05-24 10:55:01 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:5:9
|
2021-01-17 10:07:43 +00:00
|
|
|
|
|
|
|
|
LL | #![deny(unused_unsafe)]
|
|
|
|
| ^^^^^^^^^^^^^
|
|
|
|
|
2022-04-24 12:08:23 +00:00
|
|
|
error: call to unsafe function `unsf` is unsafe and requires unsafe block (error E0133)
|
2022-04-26 10:43:00 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:28:5
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
LL | unsf();
|
2022-04-24 12:42:30 +00:00
|
|
|
| ^^^^^^ call to unsafe function
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
2022-09-18 15:55:36 +00:00
|
|
|
= note: consult the function's documentation for information on how to avoid undefined behavior
|
2020-05-21 21:53:12 +00:00
|
|
|
note: the lint level is defined here
|
2022-04-26 10:43:00 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:26:8
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
LL | #[deny(warnings)]
|
|
|
|
| ^^^^^^^^
|
|
|
|
= note: `#[deny(unsafe_op_in_unsafe_fn)]` implied by `#[deny(warnings)]`
|
|
|
|
|
|
|
|
error: dereference of raw pointer is unsafe and requires unsafe block (error E0133)
|
2022-04-26 10:43:00 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:31:5
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
LL | *PTR;
|
|
|
|
| ^^^^ dereference of raw pointer
|
|
|
|
|
|
2021-05-02 21:55:22 +00:00
|
|
|
= note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
error: use of mutable static is unsafe and requires unsafe block (error E0133)
|
2022-04-26 10:43:00 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:33:5
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
LL | VOID = ();
|
2021-05-24 10:55:01 +00:00
|
|
|
| ^^^^ use of mutable static
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
= note: mutable statics can be mutated by multiple threads: aliasing violations or data races will cause undefined behavior
|
|
|
|
|
2020-05-03 21:11:58 +00:00
|
|
|
error: unnecessary `unsafe` block
|
2022-04-26 10:43:00 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:35:5
|
2021-01-17 10:07:43 +00:00
|
|
|
|
|
|
|
|
LL | unsafe {}
|
|
|
|
| ^^^^^^ unnecessary `unsafe` block
|
|
|
|
|
|
|
|
error: unnecessary `unsafe` block
|
2022-04-26 10:43:00 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:49:14
|
2020-05-03 21:11:58 +00:00
|
|
|
|
|
|
|
|
LL | unsafe { unsafe { unsf() } }
|
|
|
|
| ------ ^^^^^^ unnecessary `unsafe` block
|
|
|
|
| |
|
|
|
|
| because it's nested under this `unsafe` block
|
|
|
|
|
2022-04-24 12:08:23 +00:00
|
|
|
error[E0133]: call to unsafe function `unsf` is unsafe and requires unsafe block
|
2022-08-02 19:47:14 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:76:5
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
LL | unsf();
|
2022-04-24 12:42:30 +00:00
|
|
|
| ^^^^^^ call to unsafe function
|
2020-05-13 21:43:21 +00:00
|
|
|
|
|
|
|
|
= note: consult the function's documentation for information on how to avoid undefined behavior
|
|
|
|
|
2022-04-24 12:08:23 +00:00
|
|
|
error[E0133]: call to unsafe function `unsf` is unsafe and requires unsafe function or block
|
2022-08-02 19:47:14 +00:00
|
|
|
--> $DIR/rfc-2585-unsafe_op_in_unsafe_fn.rs:81:9
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
LL | unsf();
|
2022-04-24 12:42:30 +00:00
|
|
|
| ^^^^^^ call to unsafe function
|
2020-05-21 21:53:12 +00:00
|
|
|
|
|
|
|
|
= note: consult the function's documentation for information on how to avoid undefined behavior
|
|
|
|
|
2022-08-02 19:47:14 +00:00
|
|
|
error: aborting due to 11 previous errors
|
2020-05-03 21:11:58 +00:00
|
|
|
|
2020-05-13 21:43:21 +00:00
|
|
|
For more information about this error, try `rustc --explain E0133`.
|