fukamachi/clack — Issue #29: clack.util.route: loop warning
Author: phanalpha
Created: 2011-10-25 02:44:38+00:00
State: open

```lisp
(defmethod compile-rule ((this ))
(loop with list = (split "(?::([\\w-]+)|(\\*))" (url this)
:with-registers-p t :omit-unmatched-p t)
while list
for prefix = (pop list)
for name = (pop list)
...))
```
WARNING: LOOP: FOR clauses should occur before the loop's main body
GNU CLISP 2.48 (2009-07-28) (built 3528290451)

This would be better, in my opinion:

```lisp
(loop with list = (split "(?::([\\w-]+)|(\\*))" (url this)
:with-registers-p t :omit-unmatched-p t)
for (prefix name) on list by #'cddr
...)
```