Skip to content

Commit 6755805

Browse files
committed
normalize_newlines(): fix incorrect comment
1 parent 6351247 commit 6755805

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/rustc_span/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2105,7 +2105,7 @@ fn remove_bom(src: &mut String, normalized_pos: &mut Vec<NormalizedPos>) {
21052105

21062106
/// Replaces `\r\n` with `\n` in-place in `src`.
21072107
///
2108-
/// Returns error if there's a lone `\r` in the string.
2108+
/// Leaves any occurrences of lone `\r` unchanged.
21092109
fn normalize_newlines(src: &mut String, normalized_pos: &mut Vec<NormalizedPos>) {
21102110
if !src.as_bytes().contains(&b'\r') {
21112111
return;

0 commit comments

Comments
 (0)