Skip to content

Commit a0efdf2

Browse files
committed
Do not count \r as part of line width.
Resolves #1335. Does not attempt to handle a `\r` not followed by a `\n` nor attempt to handle Unicode intricacies (#6) including zero-width or multi-byte characters.
1 parent 3edc184 commit a0efdf2

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

src/lib.rs

-1
Original file line numberDiff line numberDiff line change
@@ -481,7 +481,6 @@ fn format_lines(text: &mut StringBuffer, name: &str, config: &Config, report: &m
481481

482482
for (c, b) in text.chars() {
483483
if c == '\r' {
484-
line_len += c.len_utf8();
485484
continue;
486485
}
487486

0 commit comments

Comments
 (0)