diff options
| author | Lars Ingebrigtsen | 2019-10-20 12:16:56 +0200 |
|---|---|---|
| committer | Lars Ingebrigtsen | 2019-10-20 12:17:28 +0200 |
| commit | 4503af6c9eacb2a3d9ef15748b66c6a453f797a4 (patch) | |
| tree | 50e1004400105d82dbce9b77683a4dba13e7eb42 | |
| parent | e8b3a15cb6ff187ce08afcb43bd9a0b7907268ca (diff) | |
| download | emacs-4503af6c9eacb2a3d9ef15748b66c6a453f797a4.tar.gz emacs-4503af6c9eacb2a3d9ef15748b66c6a453f797a4.zip | |
Fix up previous edebug breakpoint overlay change
* lisp/emacs-lisp/edebug.el (edebug--overlay-breakpoints): Only
make the overlays in edebug mode, so that we remove them when we
exit.
| -rw-r--r-- | lisp/emacs-lisp/edebug.el | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/lisp/emacs-lisp/edebug.el b/lisp/emacs-lisp/edebug.el index a19ac3bc602..e0bf52af473 100644 --- a/lisp/emacs-lisp/edebug.el +++ b/lisp/emacs-lisp/edebug.el | |||
| @@ -3198,12 +3198,14 @@ the breakpoint." | |||
| 3198 | ;; First remove all old breakpoint overlays. | 3198 | ;; First remove all old breakpoint overlays. |
| 3199 | (edebug--overlay-breakpoints-remove | 3199 | (edebug--overlay-breakpoints-remove |
| 3200 | start (+ start (aref offsets (1- (length offsets))))) | 3200 | start (+ start (aref offsets (1- (length offsets))))) |
| 3201 | ;; Then make overlays for the breakpoints. | 3201 | ;; Then make overlays for the breakpoints (but only when we are in |
| 3202 | (dolist (breakpoint breakpoints) | 3202 | ;; edebug mode). |
| 3203 | (let* ((pos (+ start (aref offsets (car breakpoint)))) | 3203 | (when edebug-active |
| 3204 | (overlay (make-overlay pos (1+ pos)))) | 3204 | (dolist (breakpoint breakpoints) |
| 3205 | (overlay-put overlay 'edebug t) | 3205 | (let* ((pos (+ start (aref offsets (car breakpoint)))) |
| 3206 | (overlay-put overlay 'face 'highlight))))) | 3206 | (overlay (make-overlay pos (1+ pos)))) |
| 3207 | (overlay-put overlay 'edebug t) | ||
| 3208 | (overlay-put overlay 'face 'highlight)))))) | ||
| 3207 | 3209 | ||
| 3208 | (defun edebug--overlay-breakpoints-remove (start end) | 3210 | (defun edebug--overlay-breakpoints-remove (start end) |
| 3209 | (dolist (overlay (overlays-in start end)) | 3211 | (dolist (overlay (overlays-in start end)) |