Fix i256::MAX
This commit is contained in:
committed by
Trevor Gross
parent
65663b538f
commit
d16c82dba1
@@ -65,7 +65,7 @@ impl MinInt for i256 {
|
||||
const ZERO: Self = Self([0u64; 4]);
|
||||
const ONE: Self = Self([1, 0, 0, 0]);
|
||||
const MIN: Self = Self([0, 0, 0, 1 << 63]);
|
||||
const MAX: Self = Self([u64::MAX, u64::MAX, u64::MAX, u64::MAX << 1]);
|
||||
const MAX: Self = Self([u64::MAX, u64::MAX, u64::MAX, u64::MAX >> 1]);
|
||||
}
|
||||
|
||||
macro_rules! impl_common {
|
||||
|
||||
@@ -83,7 +83,7 @@ impl MinInt for i256 {
|
||||
};
|
||||
const MAX: Self = Self {
|
||||
lo: u128::MAX,
|
||||
hi: u128::MAX << 1,
|
||||
hi: u128::MAX >> 1,
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user