Rename debug! macro to impl_Debug!
This commit is contained in:
parent
918dc38733
commit
0637517da6
1 changed files with 7 additions and 5 deletions
|
@ -167,7 +167,8 @@ integer! { i16, u16 }
|
||||||
integer! { i32, u32 }
|
integer! { i32, u32 }
|
||||||
integer! { i64, u64 }
|
integer! { i64, u64 }
|
||||||
integer! { i128, u128 }
|
integer! { i128, u128 }
|
||||||
macro_rules! debug {
|
|
||||||
|
macro_rules! impl_Debug {
|
||||||
($($T:ident)*) => {$(
|
($($T:ident)*) => {$(
|
||||||
#[stable(feature = "rust1", since = "1.0.0")]
|
#[stable(feature = "rust1", since = "1.0.0")]
|
||||||
impl fmt::Debug for $T {
|
impl fmt::Debug for $T {
|
||||||
|
@ -184,10 +185,6 @@ macro_rules! debug {
|
||||||
}
|
}
|
||||||
)*};
|
)*};
|
||||||
}
|
}
|
||||||
debug! {
|
|
||||||
i8 i16 i32 i64 i128 isize
|
|
||||||
u8 u16 u32 u64 u128 usize
|
|
||||||
}
|
|
||||||
|
|
||||||
// 2 digit decimal look up table
|
// 2 digit decimal look up table
|
||||||
static DEC_DIGITS_LUT: &[u8; 200] = b"0001020304050607080910111213141516171819\
|
static DEC_DIGITS_LUT: &[u8; 200] = b"0001020304050607080910111213141516171819\
|
||||||
|
@ -510,6 +507,11 @@ macro_rules! impl_Exp {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl_Debug! {
|
||||||
|
i8 i16 i32 i64 i128 isize
|
||||||
|
u8 u16 u32 u64 u128 usize
|
||||||
|
}
|
||||||
|
|
||||||
// Include wasm32 in here since it doesn't reflect the native pointer size, and
|
// Include wasm32 in here since it doesn't reflect the native pointer size, and
|
||||||
// often cares strongly about getting a smaller code size.
|
// often cares strongly about getting a smaller code size.
|
||||||
#[cfg(any(target_pointer_width = "64", target_arch = "wasm32"))]
|
#[cfg(any(target_pointer_width = "64", target_arch = "wasm32"))]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue