Function: diff-after-change-function
diff-after-change-function is a byte-compiled function defined in
diff-mode.el.gz.
Signature
(diff-after-change-function BEG END LEN)
Documentation
Remember to fixup the hunk header.
See after-change-functions for the meaning of BEG, END and LEN.
Source Code
;; Defined in /usr/src/emacs/lisp/vc/diff-mode.el.gz
(defun diff-after-change-function (beg end _len)
"Remember to fixup the hunk header.
See `after-change-functions' for the meaning of BEG, END and LEN."
;; Ignoring changes when inhibit-read-only is set is strictly speaking
;; incorrect, but it turns out that inhibit-read-only is normally not set
;; inside editing commands, while it tends to be set when the buffer gets
;; updated by an async process or by a conversion function, both of which
;; would rather not be uselessly slowed down by this hook.
(when (and (not undo-in-progress) (not inhibit-read-only))
(if diff-unhandled-changes
(setq diff-unhandled-changes
(cons (min beg (car diff-unhandled-changes))
(max end (cdr diff-unhandled-changes))))
(setq diff-unhandled-changes (cons beg end)))))