Rename debug! macro to impl_Debug! · qinheping/verify-rust-std@148ed85 (original) (raw)

Original file line number Diff line number Diff line change
@@ -167,7 +167,8 @@ integer! { i16, u16 }
167 167 integer! { i32, u32 }
168 168 integer! { i64, u64 }
169 169 integer! { i128, u128 }
170 -macro_rules! debug {
170 +
171 +macro_rules! impl_Debug {
171 172 ($($T:ident)*) => {$(
172 173 #[stable(feature = "rust1", since = "1.0.0")]
173 174 impl fmt::Debug for $T {
@@ -184,10 +185,6 @@ macro_rules! debug {
184 185 }
185 186 )*};
186 187 }
187 -debug! {
188 -i8 i16 i32 i64 i128 isize
189 -u8 u16 u32 u64 u128 usize
190 -}
191 188
192 189 // 2 digit decimal look up table
193 190 static DEC_DIGITS_LUT: &[u8; 200] = b"0001020304050607080910111213141516171819\
@@ -510,6 +507,11 @@ macro_rules! impl_Exp {
510 507 };
511 508 }
512 509
510 +impl_Debug! {
511 +i8 i16 i32 i64 i128 isize
512 +u8 u16 u32 u64 u128 usize
513 +}
514 +
513 515 // Include wasm32 in here since it doesn't reflect the native pointer size, and
514 516 // often cares strongly about getting a smaller code size.
515 517 #[cfg(any(target_pointer_width = "64", target_arch = "wasm32"))]