]> git.eshelyaron.com Git - emacs.git/commitdiff
(eval-last-sexp-1): Return the value of the evaluated form.
authorRichard M. Stallman <rms@gnu.org>
Tue, 6 Nov 2001 04:44:51 +0000 (04:44 +0000)
committerRichard M. Stallman <rms@gnu.org>
Tue, 6 Nov 2001 04:44:51 +0000 (04:44 +0000)
lisp/emacs-lisp/lisp-mode.el

index 34321783b813774587b6d23b8f5def96df117f43..6b110dbd9f7d85ba4e9fcc393b31d3ca1855bcfd 100644 (file)
@@ -482,17 +482,18 @@ With argument, print output into current buffer."
            (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)