Skip to content

Commit

Permalink
Fix off-by-one error in line number continuation
Browse files Browse the repository at this point in the history
  • Loading branch information
eth-p committed Feb 12, 2024
1 parent 5a2a20a commit fbaf3b1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/decorations.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ impl Decoration for LineNumberDecoration {
_printer: &InteractivePrinter,
) -> DecorationText {
if continuation {
if line_number > self.cached_wrap_invalid_at {
if line_number >= self.cached_wrap_invalid_at {
let new_width = self.cached_wrap.width + 1;
return DecorationText {
text: self.color.paint(" ".repeat(new_width)).to_string(),
Expand Down

0 comments on commit fbaf3b1

Please sign in to comment.