Skip to content

Commit

Permalink
fix(lsp): goto_line_backward abs_pos
Browse files Browse the repository at this point in the history
fix book-keeping of [abs_pos] in [String_zipper.goto_line_backward]
  • Loading branch information
emilienlemaire authored and rgrinberg committed May 17, 2024
1 parent 93f214d commit 7ad4e82
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lsp/src/string_zipper.ml
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ let drop_until from until =
| [] -> empty
| current :: left ->
let rel_pos = Substring.length current in
let abs_pos = from.rel_pos + rel_pos in
let abs_pos = from.abs_pos + rel_pos in
{ from with right; left; current; rel_pos; abs_pos })

let add_buffer_between b start stop =
Expand Down

0 comments on commit 7ad4e82

Please sign in to comment.