[slime-devel] Re: error message
Tamas K Papp
tpapp at Princeton.EDU
Thu Jul 5 14:11:53 UTC 2007
On Sun, Apr 08, 2007 at 04:10:53PM +0200, Marco Baringer wrote:
Hi Marco,
Sorry for the late reply.
> Tamas K Papp <tpapp at Princeton.EDU> writes:
>
> > Hi,
> >
> > If I send a function that generates a warning to the inferior lisp
> > process, slime gives this error message:
> >
> > error in process filter: Wrong number of arguments: (lambda (f startval l) "reduce the list l by the binary function f.
> > Use start value startval (cf MacLennnan p. 396)" (cond ((null l) startval) (t (apply f (list (car l) (reduce f startval (cdr l))))))), 4
> >
> > For example, if the function is
> >
> > (defun foo (bar)
> > nil)
> >
> > and I press C-c C-c, I get the error message (because of the cmucl
> > warning that bar is not used). Am I doing something wrong? I am a
> > Lisp newbie.
>
> i can't repeat this (emacs 21.4 and latest slime). can you try
> upgrading to slime cvs first? if the problem persists can you send the
> copy of the emacs backtrace and the contents of *slime-events*?
I have tried the June 20th slime tarball and the error is still here,
I attached the backtrace and *slime-events*.
Tamas
-------------- next part --------------
Debugger entered--Lisp error: (wrong-number-of-arguments (lambda (f startval l) "reduce the list l by the binary function f.
Use start value startval (cf MacLennnan p. 396)" (cond ((null l) startval) (t (apply f (list (car l) (reduce f startval (cdr l))))))) 4)
reduce(slime-most-severe ((:message "--> PROGN EVAL-WHEN \n==>\n (SB-IMPL::%DEFUN 'FOO (SB-INT:NAMED-LAMBDA FOO (BAR) (BLOCK FOO NIL)) NIL\n 'NIL (SB-C:SOURCE-LOCATION))\nThe variable BAR is defined but never used." :severity :style-warning :location (:location ... ... nil) :references nil :short-message "The variable BAR is defined but never used.")) :key slime-note\.severity)
(let* ((new-severity ...) (new-message ...) (new-references ...)) (let (...) (setf ... new-message) (setf ... new-severity) (setf ... new-references) new-note))
slime-merge-notes(((:message "--> PROGN EVAL-WHEN \n==>\n (SB-IMPL::%DEFUN 'FOO (SB-INT:NAMED-LAMBDA FOO (BAR) (BLOCK FOO NIL)) NIL\n 'NIL (SB-C:SOURCE-LOCATION))\nThe variable BAR is defined but never used." :severity :style-warning :location (:location ... ... nil) :references nil :short-message "The variable BAR is defined but never used.")))
mapcar(slime-merge-notes (((:message "--> PROGN EVAL-WHEN \n==>\n (SB-IMPL::%DEFUN 'FOO (SB-INT:NAMED-LAMBDA FOO (BAR) (BLOCK FOO NIL)) NIL\n 'NIL (SB-C:SOURCE-LOCATION))\nThe variable BAR is defined but never used." :severity :style-warning :location ... :references nil :short-message "The variable BAR is defined but never used."))))
slime-merge-notes-for-display(((:message "--> PROGN EVAL-WHEN \n==>\n (SB-IMPL::%DEFUN 'FOO (SB-INT:NAMED-LAMBDA FOO (BAR) (BLOCK FOO NIL)) NIL\n 'NIL (SB-C:SOURCE-LOCATION))\nThe variable BAR is defined but never used." :severity :style-warning :location (:location ... ... nil) :references nil :short-message "The variable BAR is defined but never used.")))
(mapc (function slime-overlay-note) (slime-merge-notes-for-display notes))
(save-excursion (slime-remove-old-overlays) (mapc (function slime-overlay-note) (slime-merge-notes-for-display notes)))
(progn (when with-temp-message (setq current-message ...) (message "%s" with-temp-message)) (save-excursion (slime-remove-old-overlays) (mapc ... ...)))
(unwind-protect (progn (when with-temp-message ... ...) (save-excursion ... ...)) (and with-temp-message (if current-message ... ...)))
(let ((with-temp-message "Highlighting notes...") (current-message)) (unwind-protect (progn ... ...) (and with-temp-message ...)))
(with-temp-message "Highlighting notes..." (save-excursion (slime-remove-old-overlays) (mapc ... ...)))
slime-highlight-notes(((:message "--> PROGN EVAL-WHEN \n==>\n (SB-IMPL::%DEFUN 'FOO (SB-INT:NAMED-LAMBDA FOO (BAR) (BLOCK FOO NIL)) NIL\n 'NIL (SB-C:SOURCE-LOCATION))\nThe variable BAR is defined but never used." :severity :style-warning :location (:location ... ... nil) :references nil :short-message "The variable BAR is defined but never used.")))
(progn (slime-highlight-notes notes))
(if slime-highlight-compiler-notes (progn (slime-highlight-notes notes)))
(when slime-highlight-compiler-notes (slime-highlight-notes notes))
(let* ((--cl-rest-- result) (result ...) (secs ...)) (slime-show-note-counts notes secs) (when slime-highlight-compiler-notes (slime-highlight-notes notes)))
(progn (let* (... ... ...) (slime-show-note-counts notes secs) (when slime-highlight-compiler-notes ...)))
(destructuring-bind (result secs) result (slime-show-note-counts notes secs) (when slime-highlight-compiler-notes (slime-highlight-notes notes)))
(save-current-buffer (set-buffer buffer) (setf slime-compilation-just-finished t) (destructuring-bind (result secs) result (slime-show-note-counts notes secs) (when slime-highlight-compiler-notes ...)))
(with-current-buffer buffer (setf slime-compilation-just-finished t) (destructuring-bind (result secs) result (slime-show-note-counts notes secs) (when slime-highlight-compiler-notes ...)))
(let ((notes ...)) (with-current-buffer buffer (setf slime-compilation-just-finished t) (destructuring-bind ... result ... ...)) (run-hook-with-args (quote slime-compilation-finished-hook) notes window-config))
slime-compilation-finished(("T" "0.01") #<buffer foo.lisp> nil)
(lambda (G40537 G40538 result) (slime-compilation-finished result (symbol-value G40538) (symbol-value G40537)))(--config-- --buffer-- ("T" "0.01"))
apply((lambda (G40537 G40538 result) (slime-compilation-finished result (symbol-value G40538) (symbol-value G40537))) --config-- --buffer-- ("T" "0.01"))
(lambda (&rest --cl-rest--) (apply (lambda ... ...) (quote --config--) (quote --buffer--) --cl-rest--))(("T" "0.01"))
funcall((lambda (&rest --cl-rest--) (apply (lambda ... ...) (quote --config--) (quote --buffer--) --cl-rest--)) ("T" "0.01"))
(if (symbol-value G40543) (funcall (symbol-value G40543) result))
(let* ((--cl-rest-- rand-40541) (result ...)) (if (symbol-value G40543) (funcall ... result)))
(cond ((eql op-40540 ...) (let* ... ...)) ((eql op-40540 ...) (let* ... ... ...)) (t (error "Elisp destructure-case failed: %S" tmp-40542)))
(let* ((tmp-40542 G40539) (op-40540 ...) (rand-40541 ...)) (cond (... ...) (... ...) (t ...)))
(lambda (G40543 G40539) (let* (... ... ...) (cond ... ... ...)))(--cont-- (:ok ("T" "0.01")))
apply((lambda (G40543 G40539) (let* (... ... ...) (cond ... ... ...))) --cont-- (:ok ("T" "0.01")))
(lambda (&rest --cl-rest--) (apply (lambda ... ...) (quote --cont--) --cl-rest--))((:ok ("T" "0.01")))
slime-dispatch-event((:return (:ok ("T" "0.01")) 5) #<process SLIME Lisp>)
slime-process-available-input(#<process SLIME Lisp>)
slime-net-filter(#<process SLIME Lisp> "00001E(:return (:ok (\"T\" \"0.01\")) 5)")
-------------- next part --------------
(:emacs-rex
(swank:connection-info)
nil t 1)
(:indentation-update
(("without-package-locks" . 0)
("with-unlocked-packages" . 1)
("with-timeout" . 1)
("define-source-context" . 2)
("defun-cached" . 2)
("with-unique-names" . 1)
("once-only" . 1)
("collect" . 1)
("with-rebound-io-syntax" . 0)
("defmacro-mundanely" . 2)
("dohash" . 1)
("named-let" . 2)
("binding*" . 1)
("with-float-traps-masked" . 1)
("prepare-for-fast-read-byte" . 1)
("awhen" . 1)
("with-sane-io-syntax" . 0)
("dovector" . 1)
("named-lambda" . 2)
("prepare-for-fast-read-char" . 1)
...))
(:return
(:ok
(:pid 32163 :style :spawn :lisp-implementation
(:type "SBCL" :name "sbcl" :version "1.0.6")
:machine
(:instance "pu100877.student.princeton.edu" :type "X86" :version "Intel(R) Pentium(R) M processor 1.73GHz")
:features
(:sb-bsd-sockets-addrinfo :asdf :clc-os-debian :common-lisp-controller :sb-futex :sb-thread :ansi-cl :common-lisp :sbcl :unix :sb-doc :sb-test :sb-ldb :sb-package-locks :sb-unicode :sb-eval :sb-source-locations :ieee-floating-point :x86 :elf ...)
:package
(:name "COMMON-LISP-USER" :prompt "CL-USER")
:version "2007-06-28"))
1)
(:emacs-rex
(swank:compile-string-for-emacs "(defun foo (bar)\n nil)\n" "foo.lisp" 172 "/tmp/")
nil t 2)
(:write-string "\n; compiling file \"/tmp/fileA6u3le.lisp\" (written 05 JUL 2007 04:09:17 PM):\n\n; file: /tmp/fileA6u3le.lisp\n; in: DEFUN FOO\n; DEFUN\n; --> PROGN EVAL-WHEN \n; ==>\n; (SB-IMPL::%DEFUN 'FOO (SB-INT:NAMED-LAMBDA FOO (BAR) (BLOCK FOO NIL)) NIL\n; 'NIL (SB-C:SOURCE-LOCATION))\n; \n; caught STYLE-WARNING:\n; The variable BAR is defined but never used.\n\n; /tmp/fileA6u3le.fasl written\n; compilation finished in 0:00:01\n; \n; compilation unit finished\n; caught 1 STYLE-WARNING condition\n")
(:return
(:ok
("T" "0.15"))
2)
(:emacs-rex
(swank:compiler-notes-for-emacs)
nil t 3)
(:return
(:ok
((:message "--> PROGN EVAL-WHEN \n==>\n (SB-IMPL::%DEFUN 'FOO (SB-INT:NAMED-LAMBDA FOO (BAR) (BLOCK FOO NIL)) NIL\n 'NIL (SB-C:SOURCE-LOCATION))\nThe variable BAR is defined but never used." :severity :style-warning :location
(:location
(:buffer "foo.lisp")
(:position 172)
nil)
:references nil :short-message "The variable BAR is defined but never used.")))
3)
(:emacs-rex
(swank:interactive-eval "(defun foo (bar)\n nil)")
nil t 4)
(:write-string "; in: LAMBDA NIL\n; SB-INT:NAMED-LAMBDA\n; ==>\n; #'(SB-INT:NAMED-LAMBDA FOO (BAR) (BLOCK FOO NIL))\n; \n; caught STYLE-WARNING:\n; The variable BAR is defined but never used.\n; \n; compilation unit finished\n; caught 1 STYLE-WARNING condition\nSTYLE-WARNING: redefining FOO in DEFUN\n")
(:return
(:ok "=> FOO")
4)
(:emacs-rex
(swank:compile-string-for-emacs "(defun foo (bar)\n nil)\n" "foo.lisp" 172 "/tmp/")
nil t 5)
(:write-string "; compiling file \"/tmp/fileQUH7jt.lisp\" (written 05 JUL 2007 04:09:35 PM):\n\n; file: /tmp/fileQUH7jt.lisp\n; in: DEFUN FOO\n; DEFUN\n; --> PROGN EVAL-WHEN \n; ==>\n; (SB-IMPL::%DEFUN 'FOO (SB-INT:NAMED-LAMBDA FOO (BAR) (BLOCK FOO NIL)) NIL\n; 'NIL (SB-C:SOURCE-LOCATION))\n; \n; caught STYLE-WARNING:\n; The variable BAR is defined but never used.\n\n; /tmp/fileQUH7jt.fasl written\n; compilation finished in 0:00:00\n; \n; compilation unit finished\n; caught 1 STYLE-WARNING condition\nSTYLE-WARNING: redefining FOO in DEFUN\n")
(:return
(:ok
("T" "0.01"))
5)
(:emacs-rex
(swank:compiler-notes-for-emacs)
nil t 6)
(:return
(:ok
((:message "--> PROGN EVAL-WHEN \n==>\n (SB-IMPL::%DEFUN 'FOO (SB-INT:NAMED-LAMBDA FOO (BAR) (BLOCK FOO NIL)) NIL\n 'NIL (SB-C:SOURCE-LOCATION))\nThe variable BAR is defined but never used." :severity :style-warning :location
(:location
(:buffer "foo.lisp")
(:position 172)
nil)
:references nil :short-message "The variable BAR is defined but never used.")))
6)
More information about the slime-devel
mailing list