-(defmacro collecting-once (&key initial-value)
- `(let* ((head ,initial-value)
- (tail ,(and initial-value `(last head))))
- (values #'(lambda (value)
- (if (null head)
- (setq head (setq tail (list value)))
- (unless (memq value head)
- (setq tail
- (cdr (rplacd tail (list value)))))))
- #'(lambda nil head))))
-
-(/show "pcl/macros.lisp 98")
-
-(defmacro doplist ((key val) plist &body body &environment env)
- (multiple-value-bind (doc decls bod)
- (extract-declarations body env)
- (declare (ignore doc))
- `(let ((.plist-tail. ,plist) ,key ,val)
- ,@decls
- (loop (when (null .plist-tail.) (return nil))
- (setq ,key (pop .plist-tail.))
- (when (null .plist-tail.)
- (error "malformed plist, odd number of elements"))
- (setq ,val (pop .plist-tail.))
- (progn ,@bod)))))
-
-(/show "pcl/macros.lisp 113")
+(defmacro doplist ((key val) plist &body body)
+ `(let ((.plist-tail. ,plist) ,key ,val)
+ (loop (when (null .plist-tail.) (return nil))
+ (setq ,key (pop .plist-tail.))
+ (when (null .plist-tail.)
+ (error "malformed plist, odd number of elements"))
+ (setq ,val (pop .plist-tail.))
+ (progn ,@body))))
+
+(/show "pcl/macros.lisp 101")