diff options
author | Marco Hinz <mh.codebro@gmail.com> | 2016-11-28 20:44:29 +0100 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2016-11-28 20:44:29 +0100 |
commit | 39bb43c5302310081bba1e987e1fcecf74ca6c14 (patch) | |
tree | d3fdcf8aa13d9dd38f191308f98424cf45cf484e | |
parent | 9956beee248bef39385449e134879cb864a5a7eb (diff) | |
download | rneovim-39bb43c5302310081bba1e987e1fcecf74ca6c14.tar.gz rneovim-39bb43c5302310081bba1e987e1fcecf74ca6c14.tar.bz2 rneovim-39bb43c5302310081bba1e987e1fcecf74ca6c14.zip |
startup: Initialize v:count1 (#5656)
The man plugin uses `v:count == v:count1` to detect if a count was explicitly
given. Unfortunately v:count1 does _not_ default to 1 but 0 during startup.
Now we set v:count1 to 1 early.
Fixes https://github.com/neovim/neovim/issues/5655
-rw-r--r-- | src/nvim/eval.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/nvim/eval.c b/src/nvim/eval.c index fc2f435508..88464b8cb0 100644 --- a/src/nvim/eval.c +++ b/src/nvim/eval.c @@ -562,6 +562,7 @@ void eval_init(void) set_vim_var_list(VV_ERRORS, list_alloc()); set_vim_var_nr(VV_SEARCHFORWARD, 1L); set_vim_var_nr(VV_HLSEARCH, 1L); + set_vim_var_nr(VV_COUNT1, 1); set_vim_var_special(VV_FALSE, kSpecialVarFalse); set_vim_var_special(VV_TRUE, kSpecialVarTrue); |