Function: viper-exec-change
viper-exec-change is a byte-compiled function defined in
viper-cmd.el.gz.
Signature
(viper-exec-change M-COM COM)
Source Code
;; Defined in /usr/src/emacs/lisp/emulation/viper-cmd.el.gz
;; define functions to be executed
;; invoked by the `C' command
(defun viper-exec-change (m-com _com)
(or (and (markerp viper-com-point) (marker-position viper-com-point))
(set-marker viper-com-point (point) (current-buffer)))
;; handle C cmd at the eol and at eob.
(if (or (and (eolp) (= viper-com-point (point)))
(= viper-com-point (point-max)))
(progn
(insert " ")(backward-char 1)))
(if (= viper-com-point (point))
(viper-forward-char-carefully))
(push-mark viper-com-point)
(if (eq m-com 'viper-next-line-at-bol)
(viper-enlarge-region (mark t) (point)))
(if (< (point) (mark t))
(exchange-point-and-mark))
(if (eq (preceding-char) ?\n)
(viper-backward-char-carefully)) ; give back the newline
(if (eq viper-intermediate-command 'viper-repeat)
(viper-change-subr (mark t) (point))
(viper-change (mark t) (point))))