rust/tests/ui/mir/unsized-extern-static.stderr
2025-09-08 19:19:59 +02:00

26 lines
893 B
Plaintext

error: argument never used
--> $DIR/unsized-extern-static.rs:11:19
|
LL | println!("C", unsafe { &symbol });
| --- ^^^^^^^^^^^^^^^^^^ argument never used
| |
| formatting specifier missing
|
help: format specifiers use curly braces, consider adding a format specifier
|
LL | println!("C{}", unsafe { &symbol });
| ++
error[E0277]: the size for values of type `[i8]` cannot be known at compilation time
--> $DIR/unsized-extern-static.rs:6:5
|
LL | pub static mut symbol: [i8];
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
|
= help: the trait `Sized` is not implemented for `[i8]`
= note: statics and constants must have a statically known size
error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0277`.