Function: cider--overlay-destroy

cider--overlay-destroy is a byte-compiled function defined in cider-overlays.el.

Signature

(cider--overlay-destroy OV &rest R)

Documentation

Delete overlay OV and its underlying text.

If any other arguments are given (collected in R), only actually do anything if the first one is non-nil. This is so it works in modification-hooks.

Source Code

;; Defined in ~/.emacs.d/elpa/cider-20260414.1619/cider-overlays.el
(defun cider--overlay-destroy (ov &rest r)
  "Delete overlay OV and its underlying text.
If any other arguments are given (collected in R), only actually do anything
if the first one is non-nil.  This is so it works in `modification-hooks'."
  (unless (and r (not (car r)))
    (let ((inhibit-modification-hooks t)
          (beg (copy-marker (overlay-start ov)))
          (end (copy-marker (overlay-end ov))))
      (delete-overlay ov)
      (delete-region beg end)
      (goto-char beg)
      (when (= (char-after) (char-before) ?\n)
        (delete-char 1)))))