We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
next_point
1 parent fcd850f commit 3250057Copy full SHA for 3250057
src/librustc_span/source_map.rs
@@ -710,7 +710,7 @@ impl SourceMap {
710
pub fn next_point(&self, sp: Span) -> Span {
711
let start_of_next_point = sp.hi().0;
712
713
- let width = self.find_width_of_character_at_span(sp, true);
+ let width = self.find_width_of_character_at_span(sp.shrink_to_hi(), true);
714
// If the width is 1, then the next span should point to the same `lo` and `hi`. However,
715
// in the case of a multibyte character, where the width != 1, the next span should
716
// span multiple bytes to include the whole character.
0 commit comments