Skip to content

Commit 3e0df4b

Browse files
committed
fix span_extend_to_next_char docs
1 parent 3fb249b commit 3e0df4b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/rustc_span/src/source_map.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -722,7 +722,7 @@ impl SourceMap {
722722
})
723723
}
724724

725-
/// Extends the given `Span` to just after the next occurrence of `c`.
725+
/// Extends the given `Span` to just before the next occurrence of `c`.
726726
pub fn span_extend_to_next_char(&self, sp: Span, c: char, accept_newlines: bool) -> Span {
727727
if let Ok(next_source) = self.span_to_next_source(sp) {
728728
let next_source = next_source.split(c).next().unwrap_or("");

0 commit comments

Comments
 (0)