Cargo fmt
This commit is contained in:
parent
45e48ec424
commit
f51261e93e
16 changed files with 192 additions and 189 deletions
|
|
@ -82,8 +82,8 @@ pub fn rewrite_string<'a>(orig: &str, fmt: &StringFormat<'a>) -> Option<String>
|
|||
// If we can't break at whitespace or punctuation, grow the string instead.
|
||||
if cur_end < cur_start + MIN_STRING {
|
||||
cur_end = cur_start + max_chars;
|
||||
while !(punctuation.contains(graphemes[cur_end - 1]) ||
|
||||
graphemes[cur_end - 1].trim().is_empty())
|
||||
while !(punctuation.contains(graphemes[cur_end - 1])
|
||||
|| graphemes[cur_end - 1].trim().is_empty())
|
||||
{
|
||||
if cur_end >= graphemes.len() {
|
||||
let line = &graphemes[cur_start..].join("");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue