changeset 40759:7441fb1a40ac

(eval-last-sexp-1): Return the value of the evaluated form.
author Richard M. Stallman <rms@gnu.org>
date Tue, 06 Nov 2001 04:44:51 +0000
parents 00382536d185
children aa9b081b3a0d
files lisp/emacs-lisp/lisp-mode.el
diffstat 1 files changed, 12 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emacs-lisp/lisp-mode.el	Tue Nov 06 04:29:38 2001 +0000
+++ b/lisp/emacs-lisp/lisp-mode.el	Tue Nov 06 04:44:51 2001 +0000
@@ -482,17 +482,18 @@
 	    (print-level eval-expression-print-level)
 	    (beg (point))
 	    end)
-	(prin1 value)
-	(setq end (point))
-	(when (and (bufferp standard-output)
-		   (or (not (null print-length))
-		       (not (null print-level)))
-		   (not (string= unabbreviated
-				 (buffer-substring-no-properties beg end))))
-	  (last-sexp-setup-props beg end value 
-				 unabbreviated
-				 (buffer-substring-no-properties beg end))
-	  )))))
+	(prog1
+	    (prin1 value)
+	  (setq end (point))
+	  (when (and (bufferp standard-output)
+		     (or (not (null print-length))
+			 (not (null print-level)))
+		     (not (string= unabbreviated
+				   (buffer-substring-no-properties beg end))))
+	    (last-sexp-setup-props beg end value 
+				   unabbreviated
+				   (buffer-substring-no-properties beg end))
+	    ))))))
 
 
 (defun eval-last-sexp (eval-last-sexp-arg-internal)