Stéphane Glondu pushed to branch upstream at Debian OCaml Maintainers / lambda-term
Commits:
-
ca5e6120
by Stephane Glondu at 2023-08-27T22:01:36+02:00
2 changed files:
Changes:
1 | +3.3.2 (2023-08-09)
|
|
2 | +------------------
|
|
3 | + |
|
4 | +* `LTerm_vi`: fix a downward-action issue when act in empty content
|
|
5 | + |
|
1 | 6 | 3.3.1 (2022-07-04)
|
2 | 7 | ------------------
|
3 | 8 |
1 | 1 | (*
|
2 | 2 | * lTerm_vi.ml
|
3 | 3 | * ------------
|
4 | - * Copyright : (c) 2020, ZAN DoYe <zandoye@gmail.com>
|
|
4 | + * Copyright : (c) 2023, ZAN DoYe <zandoye@gmail.com>
|
|
5 | 5 | * Licence : BSD3
|
6 | 6 | *
|
7 | 7 | * This file is a part of Lambda-Term.
|
... | ... | @@ -242,7 +242,7 @@ module Query = struct |
242 | 242 | let cursor= Zed_edit.cursor ctx in
|
243 | 243 | let count= Zed_lines.count lines in
|
244 | 244 | if index = Zed_lines.count lines then
|
245 | - Zed_rope.length text - 1
|
|
245 | + max 0 (Zed_rope.length text - 1)
|
|
246 | 246 | else begin
|
247 | 247 | let stop =
|
248 | 248 | if index + delta >= count then
|