Skip to content

Commit

Permalink
More lsp work
Browse files Browse the repository at this point in the history
  • Loading branch information
abbec committed Sep 25, 2024
1 parent aaf3d24 commit 5c02075
Show file tree
Hide file tree
Showing 4 changed files with 240 additions and 128 deletions.
5 changes: 3 additions & 2 deletions src/dged/buffer.c
Original file line number Diff line number Diff line change
Expand Up @@ -788,8 +788,9 @@ struct location buffer_end(struct buffer *buffer) {
if (buffer->lazy_row_add) {
return (struct location){.line = nlines, .col = 0};
} else {
return (struct location){.line = nlines - 1,
.col = buffer_line_length(buffer, nlines - 1)};
nlines = nlines == 0 ? 0 : nlines - 1;
return (struct location){.line = nlines,
.col = buffer_line_length(buffer, nlines)};
}
}

Expand Down
Loading

0 comments on commit 5c02075

Please sign in to comment.