
22 Jul
2008
22 Jul
'08
1:32 p.m.
On Jul 22, 2008, at 13:18 , L29Ah wrote:
outStanza | (isMessage) = outMessage | (isPresence) = outPresence | (isIQ) = outIQ
Why such a style doesn't work, so I must write ugly code like that:
Because the Haskell 98 Report specifies that guards are rewritten in a specific way, which in your case produces invalid code. See http://haskell.org/onlinereport/decls.html#pattern-bindings for details. -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery@kf8nh.com system administrator [openafs,heimdal,too many hats] allbery@ece.cmu.edu electrical and computer engineering, carnegie mellon university KF8NH