about summary refs log tree commit diff
path: root/tests/ui/statics/nested-allocations-dont-inherit-codegen-attrs.rs
blob: 0b7e659c7b75a5f7c1942f8bbef5088bc4eefa61 (plain)
1
2
3
4
5
6
7
8
9
10
11
//@ build-pass

// Make sure that the nested static allocation for `FOO` doesn't inherit `no_mangle`.
#[no_mangle]
pub static mut FOO: &mut [i32] = &mut [42];

// Make sure that the nested static allocation for `BAR` doesn't inherit `export_name`.
#[export_name = "BAR_"]
pub static mut BAR: &mut [i32] = &mut [42];

fn main() {}