changeset 40730:b1a039465517

(last-sexp-toggle-display): Cope if previous-single-property-change or next-single-char-property-change returns nil.
author Richard M. Stallman <rms@gnu.org>
date Mon, 05 Nov 2001 02:35:32 +0000
parents 650fb912b343
children 90e040626ebf
files lisp/emacs-lisp/lisp-mode.el
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emacs-lisp/lisp-mode.el	Mon Nov 05 00:14:46 2001 +0000
+++ b/lisp/emacs-lisp/lisp-mode.el	Mon Nov 05 02:35:32 2001 +0000
@@ -406,8 +406,8 @@
   (interactive)
   (let ((value (get-text-property (point) 'printed-value)))
     (when value
-      (let ((beg (previous-single-property-change (point) 'printed-value))
-	    (end (next-single-char-property-change (point) 'printed-value))
+      (let ((beg (or (previous-single-property-change (point) 'printed-value) (point)))
+	    (end (or (next-single-char-property-change (point) 'printed-value) (point)))
 	    (standard-output (current-buffer))
 	    (point (point)))
 	(delete-region beg end)