[slime-cvs] CVS slime/contrib
CVS User trittweiler
trittweiler at common-lisp.net
Fri Nov 6 19:08:39 UTC 2009
Update of /project/slime/cvsroot/slime/contrib
In directory cl-net:/tmp/cvs-serv18701/contrib
Modified Files:
slime-c-p-c.el slime-autodoc.el ChangeLog
Log Message:
* slime-autodoc.el (slime-arglist): Adapted to new code.
(slime-retrieve-arglist): New.
* slime-c-p-c.el (slime-get-arglist): Deleted.
(slime-complete-symbol*-fancy-bit): Use `slime-retrieve-arglist'.
--- /project/slime/cvsroot/slime/contrib/slime-c-p-c.el 2009/10/31 22:13:55 1.14
+++ /project/slime/cvsroot/slime/contrib/slime-c-p-c.el 2009/11/06 19:08:39 1.15
@@ -21,6 +21,7 @@
(require 'slime)
(require 'slime-parse)
(require 'slime-editing-commands)
+(require 'slime-autodoc)
(defcustom slime-c-p-c-unambiguous-prefix-p t
"If true, set point after the unambigous prefix.
@@ -83,7 +84,7 @@
(defun slime-complete-symbol*-fancy-bit ()
"Do fancy tricks after completing a symbol.
\(Insert a space or close-paren based on arglist information.)"
- (let ((arglist (slime-get-arglist (slime-symbol-at-point))))
+ (let ((arglist (slime-retrieve-arglist (slime-symbol-at-point))))
(when arglist
(let ((args
;; Don't intern these symbols
@@ -102,10 +103,6 @@
(not (minibuffer-window-active-p (minibuffer-window))))
(slime-echo-arglist))))))))
-(defun slime-get-arglist (symbol-name)
- "Return the argument list for SYMBOL-NAME."
- (slime-eval `(swank:arglist-for-echo-area (quote (,symbol-name)))))
-
(defun* slime-contextual-completions (beg end)
"Return a list of completions of the token from BEG to END in the
current buffer."
@@ -173,7 +170,6 @@
(defvar slime-c-p-c-init-undo-stack nil)
(defun slime-c-p-c-init ()
- (slime-require :swank-arglists)
;; save current state for unload
(push
`(progn
--- /project/slime/cvsroot/slime/contrib/slime-autodoc.el 2009/11/05 17:33:41 1.23
+++ /project/slime/cvsroot/slime/contrib/slime-autodoc.el 2009/11/06 19:08:39 1.24
@@ -37,14 +37,26 @@
:group 'slime-ui)
-;;; FIXME: unused?
+
(defun slime-arglist (name)
"Show the argument list for NAME."
- (interactive (list (slime-read-symbol-name "Arglist of: ")))
- (let ((arglist (slime-eval `(swank:arglist-for-echo-area '((,name))))))
- (if arglist
- (message "%s" (slime-fontify-string arglist))
- (error "Arglist not available"))))
+ (interactive (list (slime-read-symbol-name "Arglist of: " t)))
+ (let ((arglist (slime-eval `(swank:arglist-for-echo-area
+ '(,name ,slime-cursor-marker)))))
+ (if (eq arglist :not-available)
+ (and errorp (error "Arglist not available"))
+ (message "%s" (slime-fontify-string arglist)))))
+
+(defun slime-retrieve-arglist (name)
+ (let* ((name (etypecase name
+ (string name)
+ (symbol (symbol-name name))))
+ (arglist
+ (slime-eval `(swank:arglist-for-echo-area
+ '(,name ,slime-cursor-marker)))))
+ (if (eq arglist :not-available)
+ nil
+ arglist)))
;;;; Autodocs (automatic context-sensitive help)
--- /project/slime/cvsroot/slime/contrib/ChangeLog 2009/11/05 17:33:41 1.271
+++ /project/slime/cvsroot/slime/contrib/ChangeLog 2009/11/06 19:08:39 1.272
@@ -1,10 +1,18 @@
+2009-11-06 Tobias C. Rittweiler <tcr at freebits.de>
+
+ * slime-autodoc.el (slime-arglist): Adapted to new code.
+ (slime-retrieve-arglist): New.
+
+ * slime-c-p-c.el (slime-get-arglist): Deleted.
+ (slime-complete-symbol*-fancy-bit): Use `slime-retrieve-arglist'.
+
2009-11-05 Tobias C. Rittweiler <tcr at freebits.de>
* swank-arglists.lisp (print-decoded-arglist): Fix printing of
&any and &key parameters.
(test-print-arglist): Slightly adapted.
- * slime-autodoc ([test] autodoc.1): Slightly adapted.
+ * slime-autodoc.el ([test] autodoc.1): Slightly adapted.
2009-11-02 Tobias C. Rittweiler <tcr at freebits.de>
More information about the slime-cvs
mailing list