Apologies for cross posting, but I am not sure where this problem belongs
(iterage or gsll). I use slime (updated a few days ago) on sbcl 1.031 on
linux. I have problems compiling the following file:
>>>
(in-package :grid)
(defun foo ()
(iter:iter (iter:for e :Matrix-row grid::*array-3-4-double-float*)
(princ e) (princ " ")))
<<<
(the code is from the iterate.lisp file of the distribution)
Now in slime, I have problems. Evaluation works:
I can do C-x C-e to compile `foo'
I can also do C-M-x
But compilation does not. Both C-c C-c and C-c C-k will flag a compiler
error:
note:
The first argument never returns a value.
--> LET* BLOCK TAGBODY PROGN SETQ THE FUNCALL SB-C::%FUNCALL THE
==>
(SB-KERNEL:%COERCE-CALLABLE-TO-FUN #<FUNCTION # {10030285A9}>)
Same story in raw sbcl.
I looked at the iterate.lisp source code and see nothing obvious. But, I am
not sure what to make of the following: If I macro-expand the above code
(iter:iter ... (iter:for ... :matrix-row ...(...))) I get the following
expansion. The puzzling thing is thta the first argument to `funcall' is a
single hash character `#':
(let* ((#:sequence208 nil) (#:limit209 nil) (e nil) (#:index207 nil))
(block nil
(tagbody
(progn
(setq #:sequence208 *array-3-4-double-float*)
(setq #:limit209 (funcall # #:sequence208)) ;; <-----
(setq #:index207 -1))
loop-top-nil
(progn
(setq #:index207 (+ #:index207 1))
(if (>= #:index207 #:limit209)
(go loop-end-nil))
(setq e (funcall # #:sequence208 #:index207)) ;; <-----
(princ e)
(princ " "))
(progn)
(go loop-top-nil)
loop-end-nil
(progn))
nil))
Instead of the single hash mark, I would have expected the :access-fn and
:size-fn `lambda's from the (defclause-sequence matrix-row matrix-row-index
...) in iterate.lisp.
So, lots of puzzles. Not sure where this bug belongs: iterate or grid?
Thanks,
Mirko