@@ -196,39 +196,40 @@ where
196
196
}
197
197
198
198
macro_rules! floating {
199
- ( $ty: ident) => {
200
- #[ stable( feature = "rust1" , since = "1.0.0" ) ]
201
- impl Debug for $ty {
202
- fn fmt( & self , fmt: & mut Formatter <' _>) -> Result {
203
- float_to_general_debug( fmt, self )
199
+ ( $( $ty: ident) * ) => (
200
+ $(
201
+ #[ stable( feature = "rust1" , since = "1.0.0" ) ]
202
+ impl Debug for $ty {
203
+ fn fmt( & self , fmt: & mut Formatter <' _>) -> Result {
204
+ float_to_general_debug( fmt, self )
205
+ }
204
206
}
205
- }
206
207
207
- #[ stable( feature = "rust1" , since = "1.0.0" ) ]
208
- impl Display for $ty {
209
- fn fmt( & self , fmt: & mut Formatter <' _>) -> Result {
210
- float_to_decimal_display( fmt, self )
208
+ #[ stable( feature = "rust1" , since = "1.0.0" ) ]
209
+ impl Display for $ty {
210
+ fn fmt( & self , fmt: & mut Formatter <' _>) -> Result {
211
+ float_to_decimal_display( fmt, self )
212
+ }
211
213
}
212
- }
213
214
214
- #[ stable( feature = "rust1" , since = "1.0.0" ) ]
215
- impl LowerExp for $ty {
216
- fn fmt( & self , fmt: & mut Formatter <' _>) -> Result {
217
- float_to_exponential_common( fmt, self , false )
215
+ #[ stable( feature = "rust1" , since = "1.0.0" ) ]
216
+ impl LowerExp for $ty {
217
+ fn fmt( & self , fmt: & mut Formatter <' _>) -> Result {
218
+ float_to_exponential_common( fmt, self , false )
219
+ }
218
220
}
219
- }
220
221
221
- #[ stable( feature = "rust1" , since = "1.0.0" ) ]
222
- impl UpperExp for $ty {
223
- fn fmt( & self , fmt: & mut Formatter <' _>) -> Result {
224
- float_to_exponential_common( fmt, self , true )
222
+ #[ stable( feature = "rust1" , since = "1.0.0" ) ]
223
+ impl UpperExp for $ty {
224
+ fn fmt( & self , fmt: & mut Formatter <' _>) -> Result {
225
+ float_to_exponential_common( fmt, self , true )
226
+ }
225
227
}
226
- }
227
- } ;
228
+ ) *
229
+ )
228
230
}
229
231
230
- floating ! { f32 }
231
- floating ! { f64 }
232
+ floating ! { f32 f64 }
232
233
233
234
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
234
235
impl Debug for f16 {
0 commit comments