Fix shift-overflow in very old run-pass test.

This commit is contained in:
Felix S. Klock II 2015-03-23 07:04:15 -07:00
parent 4dfec6cab5
commit bb9d210c99

View File

@ -11,7 +11,7 @@
// Regression test for issue #152. // Regression test for issue #152.
pub fn main() { pub fn main() {
let mut b: uint = 1_usize; let mut b: uint = 1_usize;
while b <= 32_usize { while b < std::mem::size_of::<usize>() {
0_usize << b; 0_usize << b;
b <<= 1_usize; b <<= 1_usize;
println!("{}", b); println!("{}", b);