parse error on input
On GHC 6.4 on Mac OS X 10.3.9, the one-line file (t.hs) with
exactly the following contents
module A where m=(\n->n+)
incorrectly produces a syntax error:
~/working/bugs% ghc -c t.hs
t.hs:1:25: parse error on input `)'
The + can be replaced with - or * or > and will still produce the
same error.
AND the following one-line file (t1.hs)
module A where m=\n->n
produces the error
t1.hs:1:19: parse error on input `->'
BUT, adding a space after the = produces no error (t2.hs):
module A where m= \n->n
(Maybe =\ is parsed as one token. But that doesn't explain t.hs,
to which a space can be added and the problem doesn't go
away.)
--
Robin Bate Boerop
robin@bateboerop.name
Trac metadata
| Trac field | Value |
|---|---|
| Version | 6.4 |
| Type | Bug |
| TypeOfFailure | OtherFailure |
| Priority | normal |
| Resolution | ResolvedInvalid |
| Component | Compiler |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | |
| Operating system | |
| Architecture |