I see the difference in behaviour of the parser for newtype and data
definitions in combination with universal quantifications,
as reported by Ralf Hinze (forall for all places, October 2001), has been
fixed in GHC version 5.02.1.
I encountered a similar problem with existential quantification:
On Mac OS X GHCi 6.0 complains about a missing symbol when trying to
load package util. Wolgang Thaller told me the cause of this bug:
The problem was that there was a file called HsReadline.c. The
corresponding
object file, HsReadline.o, replaced HSreadline.o on the Mac's
case-insensitive file
In the code below the function trans is accepted by GHC 6.4, but
trans1 is not. I would expect that (x,y) is just syntactic sugar
for (,) x y, but apparently it isn't. I guess this is a bug; can
anyone explain what is going on?
Cheers,
Arthur
The Code:
data Equal a b where
Eq :: Equal
In the code below the function trans is accepted by GHC 6.4, but
trans1 is not. I would expect that (x,y) is just syntactic sugar
for (,) x y, but apparently it isn't. I guess this is a bug; can
anyone explain what is going on?
Cheers,
Arthur
The Code:
data Equal a b where
Eq :: Equal
the parser made by Arthur Baars, trading speed for
better error messages?
Maybe even the speed issue could be solved.
Speed, error messages and recovery were not my main concern when
writing the parser. I think a lot can be gained by optimizing the
combinator-based parsers. However this is no fun. I
I think it is a bug.
It also works with silly type annotations:
doy :: Y X a b - Y X a b
doy (Y (X :: foo)(X :: bar)) = Y X X
Looks like something smart is happening in the Pattern Annotation rule.
Arthur
On 29-sep-05, at 12:40, Ganesh Sittampalam wrote:
Hi,
I found it slightly surprising