Mercurial > vim
diff src/evalfunc.c @ 15279:54457fc4af0b v8.1.0648
patch 8.1.0648: custom operators can't act upon a forced motion
commit https://github.com/vim/vim/commit/5976f8ff00efcb3e155a89346e44f2ad43d2405a
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Dec 27 23:44:44 2018 +0100
patch 8.1.0648: custom operators can't act upon a forced motion
Problem: Custom operators can't act upon a forced motion. (Christian
Wellenbrock)
Solution: Add the forced motion to the mode() result. (Christian Brabandt,
closes #3490)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 27 Dec 2018 23:45:05 +0100 |
parents | a6319aca721b |
children | 890203d87ee5 |
line wrap: on
line diff
--- a/src/evalfunc.c +++ b/src/evalfunc.c @@ -8506,7 +8506,11 @@ f_mode(typval_T *argvars, typval_T *rett { buf[0] = 'n'; if (finish_op) + { buf[1] = 'o'; + // to be able to detect force-linewise/blockwise/characterwise operations + buf[2] = motion_force; + } else if (restart_edit == 'I' || restart_edit == 'R' || restart_edit == 'V') {