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 cb0097f commit 5ccc23fCopy full SHA for 5ccc23f
rustfmt-core/src/macros.rs
@@ -38,7 +38,7 @@ use expr::{rewrite_array, rewrite_call_inner};
38
use lists::{itemize_list, write_list, ListFormatting};
39
use rewrite::{Rewrite, RewriteContext};
40
use shape::{Indent, Shape};
41
-use utils::{format_visibility, mk_sp};
+use utils::{format_visibility, mk_sp, wrap_str};
42
43
const FORCED_BRACKET_MACROS: &[&str] = &["vec!"];
44
@@ -810,6 +810,7 @@ impl MacroBranch {
810
None => return None,
811
},
812
};
813
+ let new_body = wrap_str(new_body, config.max_width(), shape)?;
814
815
// Indent the body since it is in a block.
816
let indent_str = body_indent.to_string(&config);
0 commit comments