1

Chapter 22 of Practical Common Lisp explains (among other things) how to use both the keys and the values when iterating through a hash table with the loop macro:

(loop for k being the hash-keys in h using (hash-value v) ...)

The explanation is concluded with the following footnote:

Don't ask me why LOOP's authors chickened out on the no-parentheses style for the using subclause.

That's perfectly fine for the book and I don't blame Peter Seibel for not knowing it. Still, I am somewhat curious about the reasons for this design decision of. Why isn't the syntax something like

(loop for k being the hash-keys in h using hash-value v ...)

Is it easier to parse? Or is there some deeper reason behind it?

Dominik Mokriš
  • 1,118
  • 1
  • 8
  • 29

0 Answers0