[slime-cvs] CVS slime

CVS User heller heller at common-lisp.net
Sun Jan 4 20:53:48 UTC 2009


Update of /project/slime/cvsroot/slime
In directory cl-net:/tmp/cvs-serv18185

Modified Files:
	ChangeLog slime.el 
Log Message:
* slime.el (slime-local-variable-p): New function. XEmacs requires
two arguments.

--- /project/slime/cvsroot/slime/ChangeLog	2009/01/04 20:53:30	1.1631
+++ /project/slime/cvsroot/slime/ChangeLog	2009/01/04 20:53:48	1.1632
@@ -1,8 +1,13 @@
 2009-01-04  Helmut Eller  <heller at common-lisp.net>
 
+	* slime.el (slime-local-variable-p): New function. XEmacs requires
+	two arguments.
+
+2009-01-04  Helmut Eller  <heller at common-lisp.net>
+
 	* swank-cmucl.lisp (note-error-location): If possible, include the
 	filename.
-	* slime.el (slime-goto-location-position): Add a :eof as position
+	* slime.el (slime-goto-location-position): Add :eof as position
 	kind.
 
 2009-01-03  Helmut Eller  <heller at common-lisp.net>
--- /project/slime/cvsroot/slime/slime.el	2009/01/04 20:53:30	1.1096
+++ /project/slime/cvsroot/slime/slime.el	2009/01/04 20:53:48	1.1097
@@ -1011,14 +1011,14 @@
         (windows))
     (walk-windows (lambda (w) (push w windows)) nil t)
     (prog1 (pop-to-buffer (current-buffer))
-      (unless (local-variable-p 'slime-popup-buffer-restore-info)
+      (unless (slime-local-variable-p 'slime-popup-buffer-restore-info)
         (set (make-local-variable 'slime-popup-buffer-restore-info)
              (list (unless (memq (selected-window) windows)
                      (selected-window))
                    selected-window))))))
 
 (defun slime-close-popup-window ()
-  (assert (local-variable-p 'slime-popup-buffer-restore-info))
+  (assert (slime-local-variable-p 'slime-popup-buffer-restore-info))
   (destructuring-bind (created-window selected-window)
       slime-popup-buffer-restore-info
     (bury-buffer)
@@ -1031,7 +1031,7 @@
 
 (defmacro slime-save-local-variables (vars &rest body)
   `(let ((vals (cons (mapcar (lambda (var)
-                               (if (local-variable-p var)
+                               (if (slime-local-variable-p var)
                                    (cons var (eval var))))
                              ',vars)
                      (progn . ,body))))
@@ -8377,12 +8377,15 @@
     (apply #'run-hooks hooks)))
 
 (defun slime-line-number-at-pos ()
-  (cond ((fboundp 'line-number)
+  (cond ((fboundp 'line-number-at-pos)
+         (line-number-at-pos))  ; Emacs 22
+        ((fboundp 'line-number)
          (line-number))         ; XEmacs
-        ((fboundp 'line-number-at-pos)
-         (line-number-at-pos))  ; Recent GNU Emacs
         (t (1+ (count-lines 1 (point-at-bol))))))
 
+(defun slime-local-variable-p (var &optional buffer)
+  (local-variable-p var (or buffer (current-buffer)))) ; XEmacs
+
 (slime-defun-if-undefined next-single-char-property-change
     (position prop &optional object limit)
   (let ((limit (typecase limit





More information about the slime-cvs mailing list