mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-14 02:49:40 +00:00
eliminate nested match
This commit is contained in:
parent
4c4f70957b
commit
eb25ac5e11
@ -1730,13 +1730,11 @@ fn rewrite_call_inner<R>(context: &RewriteContext,
|
|||||||
let fmt = ListFormatting {
|
let fmt = ListFormatting {
|
||||||
tactic: tactic,
|
tactic: tactic,
|
||||||
separator: ",",
|
separator: ",",
|
||||||
trailing_separator: if force_no_trailing_comma {
|
trailing_separator: if force_no_trailing_comma ||
|
||||||
|
context.config.fn_call_style == IndentStyle::Visual {
|
||||||
SeparatorTactic::Never
|
SeparatorTactic::Never
|
||||||
} else {
|
} else {
|
||||||
match context.config.fn_call_style {
|
context.config.trailing_comma
|
||||||
IndentStyle::Visual => SeparatorTactic::Never,
|
|
||||||
IndentStyle::Block => context.config.trailing_comma,
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
shape: nested_shape,
|
shape: nested_shape,
|
||||||
ends_with_newline: false,
|
ends_with_newline: false,
|
||||||
|
Loading…
Reference in New Issue
Block a user