The less-familiar parts of Lisp for beginners — with-package-iterator

The with-package-iterator macro gives access to the symbols in one or more packages, optionally filtering by whether the symbols are external, internal, or inherited.  The macro allows the programmer to retrieve essentially the same information available with do-symbols, but with a different API.

Frankly, the presence of this macro is a bit surprising to me.  I don’t see how it adds any behaviour that can’t be easily reproduced with a simple application of do-symbols, and the Lisp standard does demonstrate fairly good orthogonality, so I don’t really understand what with-package-iterator is doing as part of the standard.  If anybody can enlighten me in the comments, that would be nice.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

*

反垃圾邮件 / Anti-spam question * Time limit is exhausted. Please reload CAPTCHA.