@@ -899,23 +899,20 @@ nonzero_unsigned_is_power_of_two! { NonZeroU8 NonZeroU16 NonZeroU32 NonZeroU64 N
899
899
macro_rules! nonzero_min_max {
900
900
( $( $min: expr , $Ty: ident( $Int: ty) ; ) + ) => {
901
901
$(
902
-
903
902
impl $Ty {
904
- #[ unstable( feature = "nonzero_max" , issue = "89065" ) ]
903
+ #[ unstable( feature = "nonzero_max" , issue = "89065" ) ]
905
904
#[ doc = concat!( "The maximum value for a`" , stringify!( $Ty) , "` is the same as `" , stringify!( $Int) , "`" ) ]
906
905
#[ doc = concat!( "assert_eq!(" , stringify!( $Ty) , "::MAX, " , stringify!( $Int) , "::MAX);" ) ]
907
- //SAFETY: Since the MAX value, for any supported integer type, is greater than 0,
908
- // the MAX will always be non-zero.
906
+ // SAFETY: Since the MAX value, for any supported integer type, is greater than 0, the MAX will always be non-zero.
909
907
pub const MAX : $Ty = unsafe { $Ty:: new_unchecked( <$Int>:: MAX ) } ;
910
908
#[ unstable( feature = "nonzero_min" , issue = "89065" ) ]
911
909
#[ doc = concat!( "The minimum value for a`" , stringify!( $Ty) , "`." ) ]
912
- /// # Examples
913
- ///
910
+ /// # Examples
914
911
#[ doc = concat!( "assert_eq!(" , stringify!( $Ty) , "::MIN, " , stringify!( $min) , ";" ) ]
915
- // SAFETY: In the signed case, the minimum integer is negative, and therefore non-zero.
916
- // In the unsignedd case, we use one, which is non-zero.
912
+ // SAFETY: In the signed case, the minimum integer is negative, and therefore non-zero.
913
+ // SAFETY: In the unsignedd case, we use one, which is non-zero.
917
914
pub const MIN : $Ty = unsafe { $Ty:: new_unchecked( $min) } ;
918
- }
915
+ }
919
916
) +
920
917
}
921
918
}
0 commit comments