0
0
mirror of https://github.com/vim/vim.git synced 2025-09-24 03:44:06 -04:00

updated for version 7.4.083

Problem:    It's hard to avoid adding a used pattern to the search history.
Solution:   Add the ":keeppatterns" modifier. (Christian Brabandt)
This commit is contained in:
Bram Moolenaar
2013-11-09 05:30:26 +01:00
parent 8e69b4a319
commit a939e43440
6 changed files with 20 additions and 0 deletions

View File

@@ -5498,6 +5498,9 @@ add_to_history(histype, new_entry, in_map, sep)
if (hislen == 0) /* no history */
return;
if (cmdmod.keeppatterns && histype == HIST_SEARCH)
return;
/*
* Searches inside the same mapping overwrite each other, so that only
* the last line is kept. Be careful not to remove a line that was moved