Files
neovim/runtime/lua/vim
Volodymyr Chernetskyi 9a8966879a fix(iter): keep take() predicate within bounds #41635
Problem:
`IterArray:take()` iterates up to `self._tail`, but `_tail` is
exclusive. When no element fails the predicate, the loop reads one index
past the last element and calls the predicate with `nil`.

Solution:
Stop at `self._tail - inc`, which is the last in-range index for both
iteration directions. Add tests using a predicate which dereferences its
argument and matches every element, forward and reversed.

AI-assisted
2026-09-03 03:23:45 -04:00
..
2026-07-25 12:47:51 -04:00
2026-01-09 10:07:15 +01:00
2026-08-25 13:32:25 +02:00