[slime-cvs] CVS update: slime/slime.el

Helmut Eller heller at common-lisp.net
Mon Nov 7 08:28:35 UTC 2005


Update of /project/slime/cvsroot/slime
In directory common-lisp.net:/tmp/cvs-serv5091

Modified Files:
	slime.el 
Log Message:
(slime-eval-macroexpand): Use lisp-mode (and font-lock-mode) when
dispaying the expansion.  Suggested by Jan Rychter.

Date: Mon Nov  7 09:28:35 2005
Author: heller

Index: slime/slime.el
diff -u slime/slime.el:1.561 slime/slime.el:1.562
--- slime/slime.el:1.561	Fri Nov  4 10:06:29 2005
+++ slime/slime.el	Mon Nov  7 09:28:34 2005
@@ -6580,7 +6580,8 @@
   (hyperspec-lookup symbol-name))
   
 (defun slime-show-description (string package)
-  (slime-with-output-to-temp-buffer ("*SLIME Description*") package (princ string)))
+  (slime-with-output-to-temp-buffer ("*SLIME Description*")
+      package (princ string)))
 
 (defun slime-describe-symbol (symbol-name)
   "Describe the symbol at point."
@@ -6954,8 +6955,12 @@
 ;;;; Macroexpansion
 
 (defun slime-eval-macroexpand (expander)
-  (let ((string (slime-sexp-at-point)))
-    (slime-eval-describe `(,expander ,string))))
+  (lexical-let ((package (slime-current-package)))
+    (slime-eval-async `(,expander ,(slime-sexp-at-point))
+     (lambda (expansion)
+       (slime-with-output-to-temp-buffer 
+           ("*SLIME macroexpansion*" lisp-mode) package
+         (insert expansion))))))
 
 (defun slime-macroexpand-1 (&optional repeatedly)
   "Display the macro expansion of the form at point.  The form is




More information about the slime-cvs mailing list