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

Helmut Eller heller at common-lisp.net
Fri Jul 30 19:30:47 UTC 2004


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

Modified Files:
	slime.el 
Log Message:
(slime-connection): Say "No default connection selected" if there are
open connections but no default connection.

(slime-tree-indent-item): Point wasn't updated correctly if the last
line was empty.  Use insert-before-markers instead of insert to do it
properly.

(slime-draw-connection-list): Don't break if there is no default
connection.

Date: Fri Jul 30 12:30:47 2004
Author: heller

Index: slime/slime.el
diff -u slime/slime.el:1.382 slime/slime.el:1.383
--- slime/slime.el:1.382	Thu Jul 29 20:48:18 2004
+++ slime/slime.el	Fri Jul 30 12:30:47 2004
@@ -1542,7 +1542,9 @@
   (let ((conn (or slime-dispatching-connection
                   slime-buffer-connection
                   slime-default-connection)))
-    (cond ((null conn)
+    (cond ((and (not conn) slime-net-processes)
+           (error "No default connection selected."))
+          ((not conn)
            (error "Not connected."))
           ((not (eq (process-status conn) 'open))
            (error "Connection closed."))
@@ -3286,8 +3288,7 @@
             (push (cons k (list e)) alist))))
     ;; Put them back in order.
     (loop for (key . value) in alist
-          collect (cons key (cons (car value)
-                                  (reverse (cdr value)))))))
+          collect (cons key (reverse value)))))
 
 (defun slime-note.severity (note)
   (plist-get note :severity))
@@ -3445,11 +3446,11 @@
 (defun slime-tree-indent-item (start end prefix)
   "Insert PREFIX at the beginning of each but the first line.
 This is used for labels spanning multiple lines."
-  (save-excursion 
+  (save-excursion
     (goto-char end)
     (beginning-of-line)
     (while (< start (point))
-      (insert prefix)
+      (insert-before-markers prefix)
       (forward-line -1))))
 
 (defun slime-tree-insert (tree prefix)
@@ -4762,7 +4763,7 @@
                                 'slime-display-eval-result)))
 
 (defun slime-display-eval-result (value)
-  (slime-message (format "%s" value)))
+  (slime-message "%s" value))
 
 (defun slime-eval-with-transcript (form &optional fn)
   "Send FROM and PACKAGE to Lisp and pass the result to FN.
@@ -6288,7 +6289,7 @@
 
 (defun slime-draw-connection-list ()
   (let ((default-pos nil)
-        (default (slime-connection))
+        (default slime-default-connection)
         (fstring "%s%2s  %-7s  %-17s  %-7s %-s\n"))
     (insert (format fstring " " "Nr" "Name" "Port" "Pid" "Type")
             (format fstring " " "--" "----" "----" "---" "----"))
@@ -6303,7 +6304,8 @@
                (or (process-id p) (process-contact p))
                (slime-pid p)
                (slime-lisp-implementation-type p))))
-    (goto-char default-pos)))
+    (when default 
+      (goto-char default-pos))))
 
 
 ;;;; Inspector





More information about the slime-cvs mailing list