From ed23c745ebbb0ac3526bcdba67c3f6b8f87751de Mon Sep 17 00:00:00 2001 From: Brian Smith Date: Wed, 21 Oct 2015 16:08:08 -1000 Subject: [PATCH] Document the equivalence of libc sized integer types to Rust types. Also, recommend that the Rust name be used. --- src/liblibc/lib.rs | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/src/liblibc/lib.rs b/src/liblibc/lib.rs index f310cd4152fdd..af9e970892b69 100644 --- a/src/liblibc/lib.rs +++ b/src/liblibc/lib.rs @@ -213,13 +213,36 @@ pub mod types { pub enum fpos_t {} } pub mod c99 { + /// An alias for `i8` using the C name from ``. Use `i8` + /// instead. pub type int8_t = i8; + + /// An alias for `i16` using the C name from ``. Use `i16` + /// instead. pub type int16_t = i16; + + /// An alias for `i32` using the C name from ``. Use `i32` + /// instead. pub type int32_t = i32; + + /// An alias for `i64` using the C name from ``. Use `i64` + /// instead. pub type int64_t = i64; + + /// An alias for `u8` using the C name from ``. Use `u8` + /// instead. pub type uint8_t = u8; + + /// An alias for `u16` using the C name from ``. Use `u16` + /// instead. pub type uint16_t = u16; + + /// An alias for `u32` using the C name from ``. Use `u32` + /// instead. pub type uint32_t = u32; + + /// An alias for `u64` using the C name from ``. Use `u64` + /// instead. pub type uint64_t = u64; } pub mod posix88 {