[iterate-devel] Problem with iterate and fare-matcher

Olof-Joachim Frahm Olof.Frahm at web.de
Fri Feb 5 18:29:06 UTC 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi, I've got a problem using iterate with the fare-matcher library (both
current versions).  In the following code fragment, the function FOO
does as it should, matching for the symbol QUIT from the current
package.  The function BAR however only wraps it inside the iterate
macro and then apparently produces slightly wrong code:
> (use-package '(#:fare-matcher #:iterate))
>
> (defun foo (msg)
>   (match msg
>     ('quit 42)
>     (_ 'else)))
>
> (foo 'quit)
> ;; 42
>
> (defun bar (msg)
>   (iterate
>     (leave (match msg
> 	       ('quit 42)
> 	       (_ 'else)))))
>
> (bar 'quit)
> ;; ELSE
> (bar 'fare-matcher::quit)
> ;; 42
Even with macroexpanding the two definitions I couldn't figure out where
this goes wrong, so maybe you have an idea about this.

Cheers,
Olof

- -- 
Es liegt in der menschlichen Natur, unvenrüntfig zu denken und zu handeln.
        -- nach Anatole France
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.11 (GNU/Linux)

iEYEARECAAYFAktsY3kACgkQEiTh585nXwB3jgCeNh5pUyV5D2g5f41z6iA5zJoc
lkIAn3ULA6Jy0JKDjKWLi3Q1wXsAzvag
=4EaR
-----END PGP SIGNATURE-----




More information about the iterate-devel mailing list