Explorar el Código

Rust nightly needs explicit cast from u32 to usize

Steve Jahns hace 10 años
padre
commit
fb6b4ae9df
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      src/bigint.rs

+ 1 - 1
src/bigint.rs

@@ -1014,7 +1014,7 @@ impl BigUint {
     pub fn bits(&self) -> usize {
         if self.is_zero() { return 0; }
         let zeros = self.data.last().unwrap().leading_zeros();
-        return self.data.len()*big_digit::BITS - zeros;
+        return self.data.len()*big_digit::BITS - zeros as usize;
     }
 }