blob: a7be1985286a1373dcefaf3994e0d991b62403cf (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
// FIXME https://github.com/rust-lang/rust/issues/59774
// build-fail
// normalize-stderr-test "thread.*panicked.*Metadata module not compiled.*\n" -> ""
// normalize-stderr-test "note:.*RUST_BACKTRACE=1.*\n" -> ""
// ignore-sgx no weak linkages permitted
#![feature(linkage)]
extern "C" {
#[linkage = "extern_weak"]
static foo: i32;
//~^ ERROR: must have type `*const T` or `*mut T` due to `#[linkage]` attribute
}
fn main() {
println!("{}", unsafe { foo });
}
|