#41932·neovim

multicursor: `f` only cascades if it succeeds on the primary cursor

Author: llakalaCreated Sep 15, 2026Updated Oct 1, 2026
Labelsneeds:discussionmulticursor

Problem

In follow mode, fa tries to jump each cursor to the next instance a. And if the main cursor has an a after it, then it works, and all cursors with an a after them jump. But if the primary cursor doesn't have an a after it, then the motion doesn't cascade, and the other cursors don't attempt to jump.

This regressed in d24cafc06a78f6357674c2429706303538be48da (bisected).

Steps to reproduce

bash
nvim --clean
:= vim.api.nvim_buf_set_lines(0, 0, -1, false, { " a", "  b", "   a", "    b" })
vGQ
fb
# observe that two cursors jump - second one and last one
0
fa
# observe that no cursors jump, even though the first and third one should

Expected behavior

The motion would cascade, even if it didn't "succeed" on the primary cursor - since it may succeed on others. I think f shouldn't "beep", or at least its beep should be ignored. The same of course goes for F / t / T.

System info

  • Nvim version (nvim -v): nightly commit d24cafc06a78f6357674c2429706303538be48da
  • Vim (not Nvim) behaves the same: no, no multicursor
  • Operating system/version: NixOS unstable
  • Terminal name/version: Kitty 0.48.2
  • $TERM environment variable: xterm-kitty
  • Installation: nixpkgs