We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8f615af commit 636de83Copy full SHA for 636de83
src/imports.rs
@@ -366,7 +366,8 @@ fn rewrite_nested_use_tree(
366
};
367
let list_str = write_list(&items[first_index..], &fmt)?;
368
369
- let result = if list_str.contains('\n') && context.config.imports_indent() == IndentStyle::Block
+ let result = if (list_str.contains('\n') || list_str.len() > remaining_width)
370
+ && context.config.imports_indent() == IndentStyle::Block
371
{
372
format!(
373
"{}{{\n{}{}\n{}}}",
0 commit comments