doalist and doalist*This is analogous to
dolist, but for “cdr-valued” alists. The difference is that an alist is expected and two variable names are required: one for the key and another for the value.Throws an error if one of the items in the list is not a list (cons or nil). If an entry is
nil, then both key and value will benil, to reflect the behavior ofcarandcdrwith anilargument (or should this throw an error?).The usual conventions are respected:
- An implicit
blocknamednilsurrounds the iteration construct.returnmay be used to terminate the loop immediately without performing any further iterations, returning zero or more values.- The body of the loop is an implicit
tagbody.