rust/tests/source/configs/force_multiline_block/false.rs
2018-03-02 15:07:13 +13:00

23 lines
475 B
Rust

// rustfmt-force_multiline_blocks: false
// Option forces multiline match arm and closure bodies to be wrapped in a block
fn main() {
match lorem {
Lorem::Ipsum => {
if ipsum {
println!("dolor");
}
}
Lorem::Dolor => println!("amet"),
}
}
fn main() {
result.and_then(|maybe_value| {
match maybe_value {
None => Err("oops"),
Some(value) => Ok(1),
}
});
}