Fixing some comments and format problems.
This commit is contained in:
parent
27a3195bea
commit
16d073b1f9
@ -89,12 +89,13 @@ macro_rules! byte_sized_impl
|
|||||||
)*}
|
)*}
|
||||||
}
|
}
|
||||||
|
|
||||||
byte_sized_impl!((u8, U8_BYTES) (u16, U16_BYTES));
|
byte_sized_impl!((i8, I8_BYTES) (u8, U8_BYTES));
|
||||||
byte_sized_impl!((u32, U32_BYTES) (u64, I64_BYTES));
|
byte_sized_impl!((i16, I16_BYTES) (u16, U16_BYTES));
|
||||||
byte_sized_impl!((i8, I8_BYTES) (i16, I16_BYTES));
|
byte_sized_impl!((i32, I32_BYTES) (u32, U32_BYTES));
|
||||||
byte_sized_impl!((i32, I32_BYTES) (i64, U64_BYTES));
|
byte_sized_impl!((i64, I64_BYTES) (u64, U64_BYTES));
|
||||||
|
byte_sized_impl!((isize, ISIZE_BYTES) (usize, USIZE_BYTES));
|
||||||
byte_sized_impl!((f32, F32_BYTES) (f64, F64_BYTES));
|
byte_sized_impl!((f32, F32_BYTES) (f64, F64_BYTES));
|
||||||
byte_sized_impl!((usize, USIZE_BYTES) (isize, ISIZE_BYTES));
|
|
||||||
|
|
||||||
|
|
||||||
/// This returns the amount of bytes it takes to store a string
|
/// This returns the amount of bytes it takes to store a string
|
||||||
|
@ -19,7 +19,6 @@ pub type PlatformEndian = BigEndian;
|
|||||||
/// This library does not support a mixed endian setting.
|
/// This library does not support a mixed endian setting.
|
||||||
///
|
///
|
||||||
/// Defaults to LittleEndian.
|
/// Defaults to LittleEndian.
|
||||||
//#[cfg(target_endian="little")]
|
|
||||||
#[cfg(not(target_endian="big"))]
|
#[cfg(not(target_endian="big"))]
|
||||||
pub type PlatformEndian = LittleEndian;
|
pub type PlatformEndian = LittleEndian;
|
||||||
|
|
||||||
@ -35,12 +34,16 @@ pub type NetworkEndian = BigEndian;
|
|||||||
|
|
||||||
/// Handles serialization where the most
|
/// Handles serialization where the most
|
||||||
/// significant byte is stored at the lowest address.
|
/// significant byte is stored at the lowest address.
|
||||||
|
///
|
||||||
|
/// Ex. '123' would be stored as 123.
|
||||||
pub enum BigEndian
|
pub enum BigEndian
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Handles serialization where the most
|
/// Handles serialization where the most
|
||||||
/// significant byte is stored at the lowest address.
|
/// significant byte is stored at the highest address.
|
||||||
|
///
|
||||||
|
/// Ex. '123' would be stored as 321.
|
||||||
pub enum LittleEndian
|
pub enum LittleEndian
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user