Function: vi-execute-op
vi-execute-op is a byte-compiled function defined in vi.el.gz.
Signature
(vi-execute-op OP-CHAR MOTION-COMMAND ARG)
Documentation
Execute vi edit operator as specified by OP-CHAR, the operand is the region determined by the MOTION-COMMAND with ARG.
Source Code
;; Defined in /usr/src/emacs/lisp/obsolete/vi.el.gz
;; (t (throw 'vi-exit-op (ding)))))))
(defun vi-execute-op (op-char motion-command arg)
"Execute vi edit operator as specified by OP-CHAR, the operand is the region
determined by the MOTION-COMMAND with ARG."
(cond ((= op-char ?d)
(if (vi-delete-op motion-command arg)
(vi-set-last-change-command 'vi-delete-op (vi-repeat-command-of motion-command) arg)))
((= op-char ?c)
(if (vi-delete-op motion-command arg)
(vi-goto-insert-state 1 (list 'vi-delete-op
(vi-repeat-command-of motion-command) arg) nil)))
((= op-char ?y)
(if (vi-yank-op motion-command arg)
(vi-set-last-change-command 'vi-yank-op (vi-repeat-command-of motion-command) arg)))
((= op-char ?!)
(if (vi-shell-op motion-command arg)
(vi-set-last-change-command 'vi-shell-op (vi-repeat-command-of motion-command) arg vi-last-shell-command)))
((= op-char ?<)
(if (vi-shift-op motion-command arg (- vi-shift-width))
(vi-set-last-change-command 'vi-shift-op (vi-repeat-command-of motion-command) arg (- vi-shift-width))))
((= op-char ?>)
(if (vi-shift-op motion-command arg vi-shift-width)
(vi-set-last-change-command 'vi-shift-op (vi-repeat-command-of motion-command) arg vi-shift-width)))
((= op-char ?=)
(if (vi-indent-op motion-command arg)
(vi-set-last-change-command 'vi-indent-op (vi-repeat-command-of motion-command) arg)))
((= op-char ?\\)
(vi-narrow-op motion-command arg))))