This commit is contained in:
Nicholas Ward 2023-03-16 11:28:56 -07:00
parent e0a4bc3157
commit 062eb82a8b

View File

@ -274,12 +274,10 @@ fn test_cmp_bignum_all() -> Result<()> {
for bit_size in BIT_SIZES_TO_TEST {
let a = gen_bignum(bit_size);
let b = gen_bignum(bit_size);
let output = if a < b {
MINUS_ONE
} else if a == b {
0.into()
} else {
1.into()
let output = match a.cmp(&b) {
Ordering::Less => U256::MINUS_ONE,
Ordering::Equal => 0.into(),
Ordering::Greater => 1.into(),
};
test_cmp_bignum(a, b, output)?;