From c161e8ef9f50928cf6b8cd92cdb1d45139aac275 Mon Sep 17 00:00:00 2001 From: goldenMetteyya Date: Wed, 10 Apr 2019 00:03:51 +0300 Subject: [PATCH] Update partial.rs --- src/algorithms/partial.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/algorithms/partial.rs b/src/algorithms/partial.rs index 20f7854..fb60a59 100644 --- a/src/algorithms/partial.rs +++ b/src/algorithms/partial.rs @@ -86,7 +86,7 @@ pub fn partial_bigint(op: &BigInt) -> (i64, i32) { // // extract the top word of bits from a and b // let h = a.digits()[n - 1].leading_zeros(); //let lg2 = last.leading_zeros(); - let lg2 = u64_log2(last); + let lg2 = u64_log2(last) + 1; println!("-------lg2 ------: {:?}", lg2); let mut exp = lg2 as i32;