[Haskell-cafe] Happy GLR parser creation problem

Paul Jensen neanderpaul at gmail.com
Wed Jun 2 06:55:36 EDT 2010


[Apologies if this is the wrong place to ask -- there appears to be no
Happy-specific list.]

I'm interested in experimenting with using a GLR parser to parse some
data that could be interpreted in different ways. I'm trying to use
Happy's GLR mode but I am encountering an error building one of the
examples (specifically
http://darcs.haskell.org/happy/examples/glr/expr-eval/Expr.y):

[Mac OS X 10.6.3]

rhoda:expr-eval psj$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 6.12.1

rhoda:expr-eval psj$ happy --version
Happy Version 1.18.4 Copyright (c) 1993-1996 Andy Gill, Simon Marlow
(c) 1997-2005 Simon Marlow

rhoda:expr-eval psj$ happy --glr --ghc Expr.y
shift/reduce conflicts:  9
happy: src/ProduceGLRCode.lhs:190:11-76: Irrefutable pattern failed
for pattern (pre, drop_me : post)

It's the same error someone else encountered last year, described at
http://www.haskell.org/pipermail/haskell-cafe/2009-July/063770.html .

Does anyone have any insights into this? If Happy's GLR support isn't
working just now, are there any other parser generators that produce
GLR parsers that anyone would recommend having a look at?

Many thanks,
psj


More information about the Haskell-Cafe mailing list