about summary refs log tree commit diff
path: root/tests/ui/repr/align-with-extern-c-fn.rs
blob: 659ef88fce69c4b311daa69a90391cc9c22a05b5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// run-pass

#![allow(stable_features)]
#![allow(unused_variables)]

// #45662

#![feature(repr_align)]

#[repr(align(16))]
pub struct A(#[allow(dead_code)] i64);

#[allow(improper_ctypes_definitions)]
pub extern "C" fn foo(x: A) {}

fn main() {
    foo(A(0));
}