Ok.

Yours works.  Why?  I fail to see the difference with mine.

Cheers

Marco


On Mar 21, 2008, at 19:46 , Chris Dean wrote:

Marco Antoniotti <[EMAIL PROTECTED]> writes:
Well....  any suggestions?

Here's some untested code, let me know if there are any problems with
it:

    (defmacro-driver (FOR var IN-ENUM e)
      "All elements in the enum"
      (let ((enum (gensym "ENUM-"))
            (kwd (if generate 'generate 'for)))
        `(progn
           (with ,enum = ,e)
           (,kwd ,var next (if (enum:has-more-elements-p ,enum)
                               (enum:next ,enum)
                               (terminate))))))

    (iter (for x :in-enum (enum:range 3 8))
          (collect (1+ x)))

Please note that the manual pages in HTML are not that useful.

http://common-lisp.net/project/iterate/doc/Writing- Drivers.html#Writing-Drivers

works for me

Cheers,
Chris Dean

--
Marco Antoniotti, Associate Professor                           tel.    +39 - 
02 64 48 79 01
DISCo, Università Milano Bicocca U14 2043
Viale Sarca 336
I-20126 Milan (MI) ITALY

Please note that I am not checking my Spam-box anymore.





_______________________________________________
iterate-devel site list
iterate-devel@common-lisp.net
http://common-lisp.net/mailman/listinfo/iterate-devel

Reply via email to