Upgrade to rustfmt 0.6.3

This commit is contained in:
Jakob Stoklund Olesen
2016-12-21 10:05:14 -08:00
parent 3568b93b84
commit 893a630ca0
3 changed files with 32 additions and 26 deletions

View File

@@ -30,7 +30,7 @@ function banner() {
# rustfmt is installed.
#
# This version should always be bumped to the newest version available.
RUSTFMT_VERSION="0.6.2"
RUSTFMT_VERSION="0.6.3"
if cargo install --list | grep -q "^rustfmt v$RUSTFMT_VERSION"; then
banner "Rust formatting"

View File

@@ -9,7 +9,8 @@ use self::cretonne::entity_map::EntityMap;
fn test_reverse_postorder_traversal(function_source: &str, ebb_order: Vec<u32>) {
let func = &parse_functions(function_source).unwrap()[0];
let cfg = ControlFlowGraph::new(&func);
let ebbs = ebb_order.iter().map(|n| Ebb::with_number(*n).unwrap())
let ebbs = ebb_order.iter()
.map(|n| Ebb::with_number(*n).unwrap())
.collect::<Vec<Ebb>>();
let mut postorder_ebbs = cfg.postorder_ebbs();
@@ -50,7 +51,8 @@ fn simple_traversal() {
ebb5:
trap
}
", vec![0, 2, 1, 3, 4, 5]);
",
vec![0, 2, 1, 3, 4, 5]);
}
#[test]
@@ -67,7 +69,8 @@ fn loops_one() {
ebb3:
return
}
", vec![0, 1, 2, 3]);
",
vec![0, 1, 2, 3]);
}
#[test]
@@ -91,7 +94,8 @@ fn loops_two() {
brz v0, ebb4
return
}
", vec![0, 1, 2, 5, 4, 3]);
",
vec![0, 1, 2, 5, 4, 3]);
}
#[test]
@@ -120,7 +124,8 @@ fn loops_three() {
ebb7:
return
}
", vec![0, 1, 2, 5, 4, 3, 6, 7]);
",
vec![0, 1, 2, 5, 4, 3, 6, 7]);
}
#[test]
@@ -142,5 +147,6 @@ fn back_edge_one() {
ebb4:
trap
}
", vec![0, 1, 3, 2, 4]);
",
vec![0, 1, 3, 2, 4]);
}