Skip to content

Commit 4fd4e37

Browse files
committed
---
yaml --- r: 57880 b: refs/heads/incoming c: ffa31d2 h: refs/heads/master v: v3
1 parent bbd0819 commit 4fd4e37

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ refs/heads/try: bf67eb2362b7d0f37012f2d6dac604c3bbacd2c6
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c
9-
refs/heads/incoming: e4ca2da42072fccd16aefdc4f2090b0489e8293c
9+
refs/heads/incoming: ffa31d235badfb5544ddb2de151ccfc66c8a20e6
1010
refs/heads/dist-snap: 00dbbd01c2aee72982b3e0f9511ae1d4428c3ba9
1111
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1212
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/incoming/src/libstd/num/bigint.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,7 @@ impl BigUint {
623623
let mut shifted = ~[];
624624
for self.data.each_reverse |elem| {
625625
shifted = ~[(*elem >> n_bits) | borrow] + shifted;
626-
borrow = *elem << (uint::bits - n_bits);
626+
borrow = *elem << (BigDigit::bits - n_bits);
627627
}
628628
return BigUint::new(shifted);
629629
}
@@ -1213,6 +1213,7 @@ mod biguint_tests {
12131213
check(~[1 << 2], 2, ~[1]);
12141214
check(~[1, 2], 3, ~[1 << (BigDigit::bits - 2)]);
12151215
check(~[1, 1, 2], 3 + BigDigit::bits, ~[1 << (BigDigit::bits - 2)]);
1216+
check(~[0, 1], 1, ~[0x80000000]);
12161217
test_shr_bits();
12171218

12181219
#[cfg(target_arch = "x86_64")]

0 commit comments

Comments
 (0)