[slime-cvs] CVS update: slime/swank-openmcl.lisp

Helmut Eller heller at common-lisp.net
Sun Nov 30 08:15:27 UTC 2003


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

Modified Files:
	swank-openmcl.lisp 
Log Message:
Use the new format for source locations and implement
find-function-locations (just calls the old code).
Date: Sun Nov 30 03:15:27 2003
Author: heller

Index: slime/swank-openmcl.lisp
diff -u slime/swank-openmcl.lisp:1.24 slime/swank-openmcl.lisp:1.25
--- slime/swank-openmcl.lisp:1.24	Sun Nov 23 09:16:42 2003
+++ slime/swank-openmcl.lisp	Sun Nov 30 03:15:26 2003
@@ -13,7 +13,7 @@
 ;;; The LLGPL is also available online at
 ;;; http://opensource.franz.com/preamble.html
 ;;;
-;;;   $Id: swank-openmcl.lisp,v 1.24 2003/11/23 14:16:42 lgorrie Exp $
+;;;   $Id: swank-openmcl.lisp,v 1.25 2003/11/30 08:15:26 heller Exp $
 ;;;
 
 ;;;
@@ -157,11 +157,12 @@
            :location
            (let ((position (condition-source-position condition)))
              (if *buffer-name*
-                 (list :emacs-buffer *buffer-name* position t)
-                 (list :file
-                       (ccl::compiler-warning-file-name condition)
-                       position
-                       t))))))
+                 (make-location
+                  (list :buffer *buffer-name*)
+                  (list :position position t))
+                 (make-location
+                  (list :file (ccl::compiler-warning-file-name condition))
+                  (list :position position t)))))))
 
 (defun temp-file-name ()
   "Return a temporary file name to compile strings into."
@@ -324,9 +325,12 @@
   (let ((source-info (ccl::%source-files symbol)))
     ;; This is not entirely correct---%SOURCE-FILES can apparently
     ;; return a list under some circumstances...
-    (when (and source-info (atom source-info))
-      (let ((filename (namestring (truename source-info))))
-        (list :openmcl filename (symbol-name symbol))))))
+    (cond ((and source-info (atom source-info))
+           (let ((filename (namestring (truename source-info))))
+             (make-location
+              (list :file filename)
+              (list :function-name (symbol-name symbol)))))
+          (t (list :error (format nil "No source infor for ~S"  symbol))))))
 
 (defmethod frame-source-location-for-emacs (index)
   "Return to Emacs the location of the source code for the
@@ -410,6 +414,9 @@
 precise location of the definition is not available, but we are
 able to return the file name in which the definition occurs."
   (function-source-location (from-string fname)))
+
+(defslimefun find-function-locations (fname)
+  (list (function-source-location-for-emacs fname)))
 
 ;;; Macroexpansion
 





More information about the slime-cvs mailing list