![](https://secure.gravatar.com/avatar/a447cdf7e8485010f061613330e56f7a.jpg?s=120&d=mm&r=g)
Marco Antoniotti <antoniotti.marco@disco.unimib.it> 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-Driv... works for me Cheers, Chris Dean