Open
Description
Input C/C++ Header
part of MacOSX.sdk/System/Library/Frameworks/Kernel.framework/Versions/A/Headers/hfs/hfs_format.h
#define int8_t char
struct FndrOpaqueInfo {
int8_t opaque[16];
} __attribute__((aligned(2), packed));
Bindgen Invocation
$ bindgen has_format.h
Actual Results
#[repr(C, packed(2))]
#[repr(align(2))]
#[derive(Debug, Copy, Clone)]
pub struct FndrOpaqueInfo {
pub opaque: [::std::os::raw::c_char; 16usize],
}
Expected Results
#[repr(C, packed(2))]
#[derive(Debug, Copy, Clone)]
pub struct FndrOpaqueInfo {
pub opaque: [::std::os::raw::c_char; 16usize],
}
The actual result is illegal in Rust.
#[repr(C, packed(2))]
#[repr(align(2))]
any of below will be accepted
#[repr(C, packed(2))]
#[repr(C)]
#[repr(align(2))]