Files
rust/tests/ui/consts/const-extern-fn/const-extern-fn-requires-unsafe.stderr

36 lines
1.4 KiB
Plaintext
Raw Normal View History

2023-12-07 11:56:48 +00:00
error[E0133]: call to unsafe function `foo` is unsafe and requires unsafe function or block
2024-08-29 15:33:34 +02:00
--> $DIR/const-extern-fn-requires-unsafe.rs:12:5
|
LL | foo();
| ^^^^^ call to unsafe function
|
= note: consult the function's documentation for information on how to avoid undefined behavior
2024-08-29 15:33:34 +02:00
error[E0133]: call to unsafe function `bar` is unsafe and requires unsafe function or block
--> $DIR/const-extern-fn-requires-unsafe.rs:16:5
|
LL | bar();
| ^^^^^ call to unsafe function
|
= note: consult the function's documentation for information on how to avoid undefined behavior
2023-12-07 11:56:48 +00:00
error[E0133]: call to unsafe function `foo` is unsafe and requires unsafe function or block
2024-08-29 15:33:34 +02:00
--> $DIR/const-extern-fn-requires-unsafe.rs:10:17
|
LL | let a: [u8; foo()];
| ^^^^^ call to unsafe function
|
= note: consult the function's documentation for information on how to avoid undefined behavior
2024-08-29 15:33:34 +02:00
error[E0133]: call to unsafe function `bar` is unsafe and requires unsafe function or block
--> $DIR/const-extern-fn-requires-unsafe.rs:14:17
|
LL | let b: [u8; bar()];
| ^^^^^ call to unsafe function
|
= note: consult the function's documentation for information on how to avoid undefined behavior
error: aborting due to 4 previous errors
For more information about this error, try `rustc --explain E0133`.