I don't know if it is implementation dependent. Just in case it matters, I'm using Corman Lisp 3.0

When I do something like this:

(loop for v being the hash-values of *my-hash-table*
  when (> v 1) sum v)

I get two warnings:

;;; Warning: Unused variable G9063 in anonymous function
;;; Warning: Unused variable G9062 in anonymous function

With the number of G changing every time.

The result is correct though. What do they mean? Why do they appear? I suppose there might be some kind of loop syntax misuse, which leads to these warnings, but I fail to see it.

有帮助吗?

解决方案

Corman Lisp hasn't been updated for years. The G* unused variables are probably gensyms in the macro expansion of loop. Try

(macroexpand '(loop ...))

to see what these variables store.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top