fix bug in debug! output from rustc::middle::dataflow

(bug was cut/pasted into `rustc_borrowck::bitslice`, so I fixed it
there as well.)
This commit is contained in:
Felix S. Klock II 2016-04-28 15:12:52 +02:00
parent e90307d2a2
commit cd81b60a4a
2 changed files with 4 additions and 4 deletions

View file

@ -660,8 +660,8 @@ fn set_bit(words: &mut [usize], bit: usize) -> bool {
}
fn bit_str(bit: usize) -> String {
let byte = bit >> 8;
let lobits = 1 << (bit & 0xFF);
let byte = bit >> 3;
let lobits = 1 << (bit & 0b111);
format!("[{}:{}-{:02x}]", bit, byte, lobits)
}

View file

@ -73,8 +73,8 @@ fn bit_lookup(bit: usize) -> BitLookup {
fn bit_str(bit: usize) -> String {
let byte = bit >> 8;
let lobits = 1 << (bit & 0xFF);
let byte = bit >> 3;
let lobits = 1 << (bit & 0b111);
format!("[{}:{}-{:02x}]", bit, byte, lobits)
}