Skip to content

Commit ef94b8a

Browse files
committed
Rollup merge of rust-lang#23811 - alexcrichton:libc-stable, r=Manishearth
Right now the `std::isize::BYTES` typedef is `#[unstable]`, but liblibc is using this, preventing it from compiling on stable Rust.
2 parents fa3d778 + bd66f57 commit ef94b8a

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/liblibc/lib.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,10 @@ pub mod types {
307307
#[derive(Copy)] pub struct sockaddr_storage {
308308
pub ss_family: sa_family_t,
309309
pub __ss_align: isize,
310-
pub __ss_pad2: [u8; 128 - 2 * (::core::isize::BYTES as usize)],
310+
#[cfg(target_pointer_width = "32")]
311+
pub __ss_pad2: [u8; 128 - 2 * 4],
312+
#[cfg(target_pointer_width = "64")]
313+
pub __ss_pad2: [u8; 128 - 2 * 8],
311314
}
312315
#[repr(C)]
313316
#[derive(Copy)] pub struct sockaddr_in {

0 commit comments

Comments
 (0)