Pattern guards

Claus Reinke claus.reinke at talk21.com
Fri Sep 29 14:58:57 EDT 2006


I'm not argueing against pattern guards (nor for them;-), but perhaps 
the attached translations of Conor's and David's examples might help 
to dispel some myths. For the translation idea, see my earlier email:

http://www.haskell.org/pipermail/haskell-prime/2006-February/000597.html

If it wasn't for those pesky returns/guards, one might claim the translations
to be as concise as the originals. As it stands, the results of the translation
are rather more awkward but -and this is the important point- pattern
guards do not add new functionality. And fortunately, David only asked 
for "nearly as concise":)

hth,
Claus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: PG.hs
Type: application/octet-stream
Size: 1766 bytes
Desc: not available
Url : http://www.haskell.org/pipermail/haskell-prime/attachments/20060929/374e6087/PG.obj


More information about the Haskell-prime mailing list