summaryrefslogtreecommitdiffstats
path: root/tests/run-make/issue-36710/foo.rs
blob: f30a35e27c0bcc7f596fda1de1e8007e2798c109 (plain)
1
2
3
4
5
6
7
8
9
10
// Tests that linking to C++ code with global destructors works.

extern "C" {
    fn get() -> u32;
}

fn main() {
    let i = unsafe { get() };
    assert_eq!(i, 1234);
}