Skip to content

ctrl-r ctrl-w doesn't work as expected in search mode if incsearch is on #9898

@bsdmp

Description

@bsdmp

Steps to reproduce

mv ~/.vimrc ~/vimrc
mv ~/.vim vim
vim

:set incsearch

insert two lines:
one
two

put cursor on word "one", type /^ to get into search mode, Ctrl-R Ctrl-W, word "two" will be inserted into command line

Expected behaviour

Word under cursor is expected to be inserted ("one"). If I remove :set incsearch step, all works as expected. According to #vim@libera bug is not present in 3455.

I use this method to quickly navigate through code, because '^func_name' will immediately gets me to its implementation.

Version of Vim

vim-8.2.4476-no_x11

Environment

OpenBSD current
xterm
screen-256color
ksh

Logs and stack traces

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions