I like your patch, but can you enhance it so that it works when swank is not available?
Unfortunately, swank does not modify * features *. I use to check for swank: (when (find-package: swank) ...). I added ignore-errors in case of any other swank.
If you really love loop
In my code I always use iterate:)
I modified the code in line with your comments.
Andrey