/// assert_eq!(i8::min_value(), -128);
/// ```
#[stable(feature = "rust1", since = "1.0.0")]
+ #[cfg_attr(not(stage0), rustc_const_unstable(feature = "const_min_value"))]
#[inline]
pub const fn min_value() -> Self {
!0 ^ ((!0 as $UnsignedT) >> 1) as Self
/// assert_eq!(i8::max_value(), 127);
/// ```
#[stable(feature = "rust1", since = "1.0.0")]
+ #[cfg_attr(not(stage0), rustc_const_unstable(feature = "const_max_value"))]
#[inline]
pub const fn max_value() -> Self {
!Self::min_value()
///
/// Leading and trailing whitespace represent an error.
///
+ /// # Panics
+ ///
+ /// This function panics if `radix` is not in the range from 2 to 36.
+ ///
/// # Examples
///
/// Basic usage:
/// assert_eq!(u8::min_value(), 0);
/// ```
#[stable(feature = "rust1", since = "1.0.0")]
+ #[cfg_attr(not(stage0), rustc_const_unstable(feature = "const_min_value"))]
#[inline]
pub const fn min_value() -> Self { 0 }
/// assert_eq!(u8::max_value(), 255);
/// ```
#[stable(feature = "rust1", since = "1.0.0")]
+ #[cfg_attr(not(stage0), rustc_const_unstable(feature = "const_max_value"))]
#[inline]
pub const fn max_value() -> Self { !0 }