diff --git a/src/bounds.rs b/src/bounds.rs index 191f3e1..b4aa909 100644 --- a/src/bounds.rs +++ b/src/bounds.rs @@ -29,12 +29,16 @@ bounded_impl!(u8, u8::MIN, u8::MAX); bounded_impl!(u16, u16::MIN, u16::MAX); bounded_impl!(u32, u32::MIN, u32::MAX); bounded_impl!(u64, u64::MIN, u64::MAX); +#[cfg(feature = "i128")] +bounded_impl!(u128, u128::MIN, u128::MAX); bounded_impl!(isize, isize::MIN, isize::MAX); bounded_impl!(i8, i8::MIN, i8::MAX); bounded_impl!(i16, i16::MIN, i16::MAX); bounded_impl!(i32, i32::MIN, i32::MAX); bounded_impl!(i64, i64::MIN, i64::MAX); +#[cfg(feature = "i128")] +bounded_impl!(i128, i128::MIN, i128::MAX); impl Bounded for Wrapping { fn min_value() -> Self { Wrapping(T::min_value()) } @@ -89,6 +93,9 @@ fn wrapping_bounded() { } test_wrapping_bounded!(usize u8 u16 u32 u64 isize i8 i16 i32 i64); + + #[cfg(feature = "i128")] + test_wrapping_bounded!(u128 i128); } #[test]