uint: bugfix in trailing_zeroes()
This commit is contained in:
parent
af10b153be
commit
e3c793f702
|
@ -1,7 +1,7 @@
|
|||
|
||||
[package]
|
||||
name = "bitcoin"
|
||||
version = "0.8.0"
|
||||
version = "0.8.1"
|
||||
authors = ["Andrew Poelstra <apoelstra@wpsoftware.net>"]
|
||||
license = "CC0-1.0"
|
||||
homepage = "https://github.com/apoelstra/rust-bitcoin/"
|
||||
|
|
|
@ -202,7 +202,7 @@ macro_rules! construct_uint {
|
|||
for i in 0..($n_words - 1) {
|
||||
if arr[i] > 0 { return (0x40 * i) + arr[i].trailing_zeros() as usize; }
|
||||
}
|
||||
(0x40 * ($n_words - 1)) + arr[3].trailing_zeros() as usize
|
||||
(0x40 * ($n_words - 1)) + arr[$n_words - 1].trailing_zeros() as usize
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue