Function: ediff-make-bullet-proof-overlay
ediff-make-bullet-proof-overlay is a byte-compiled function defined in
ediff-util.el.gz.
Signature
(ediff-make-bullet-proof-overlay BEG END BUFF)
Source Code
;; Defined in /usr/src/emacs/lisp/vc/ediff-util.el.gz
;;; Misc
;; In Emacs, this just makes overlay. In the future, when Emacs will start
;; supporting sticky overlays, this function will make a sticky overlay.
;; BEG and END are expressions telling where overlay starts.
;; If they are numbers or buffers, then all is well. Otherwise, they must
;; be expressions to be evaluated in buffer BUF in order to get the overlay
;; bounds.
;; If BUFF is not a live buffer, then return nil; otherwise, return the
;; newly created overlay.
(defun ediff-make-bullet-proof-overlay (beg end buff)
(if (ediff-buffer-live-p buff)
(let (overl)
(ediff-with-current-buffer buff
(or (number-or-marker-p beg)
(setq beg (eval beg)))
(or (number-or-marker-p end)
(setq end (eval end)))
;; advance front and rear of the overlay
(setq overl (make-overlay beg end buff nil 'rear-advance))
;; never detach
(ediff-overlay-put overl 'evaporate nil)
(ediff-overlay-put overl 'ediff-diff-num 0)
overl))))