rust/tests/fail/extern_static.rs
2022-07-11 11:48:56 +00:00

10 lines
218 B
Rust

//! Even referencing an unknown `extern static` already triggers an error.
extern "C" {
static mut FOO: i32;
}
fn main() {
let _val = unsafe { std::ptr::addr_of!(FOO) }; //~ ERROR: is not supported by Miri
}