RE: Haddock chokes on '#'

On 11 February 2005 17:44, Peter Simons wrote:
Processing the file
module Test where
-- |Haddock chokes on this.
(#) :: a -> (a -> b) -> b a # f = f a
with Haddock 0.6 gives an error:
| haddock test.hs | test.hs:5:3: Parse error
Since GHC deals with this code just fine, I suppose this is a bug.
Haddock parses GHC extensions by default, so its syntax corresponds to GHC with -fglasgow-exts. This could be considered a bug, but it probably won't get fixed (unless someone sends me a patch...). Cheers, Simon

Simon Marlow writes:
(#) :: a -> (a -> b) -> b a # f = f a
Haddock parses GHC extensions by default, so its syntax corresponds to GHC with -fglasgow-exts.
I see. Thanks for the clarification. Fortunately, writing ( # ) instead solves the problem. ;-) Peter
participants (2)
-
Peter Simons
-
Simon Marlow