Skip to content

Commit 64901fe

Browse files
committed
Format
1 parent 79f4dec commit 64901fe

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

src/visitor.rs

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -163,13 +163,15 @@ impl<'a> FmtVisitor<'a> {
163163

164164
let snippet =
165165
self.snippet(mk_sp(self.last_pos, attr_lo.unwrap_or(first_stmt.span.lo)));
166-
let len = CommentCodeSlices::new(&snippet).nth(0).and_then(
167-
|(kind, _, s)| if kind == CodeCharKind::Normal {
168-
s.rfind('\n')
169-
} else {
170-
None
171-
},
172-
);
166+
let len = CommentCodeSlices::new(&snippet)
167+
.nth(0)
168+
.and_then(|(kind, _, s)| {
169+
if kind == CodeCharKind::Normal {
170+
s.rfind('\n')
171+
} else {
172+
None
173+
}
174+
});
173175
if let Some(len) = len {
174176
self.last_pos = self.last_pos + BytePos::from_usize(len);
175177
}

0 commit comments

Comments
 (0)