[Haskell-cafe] ANN: alex-meta-0.1.1 and happy-meta-0.1.1

Jonas Almström Duregård jonas.duregard at chalmers.se
Wed Sep 22 11:23:53 EDT 2010

I'm pleased to announce alex-meta and happy-meta! These libraries provide
quasi-quoter frontends and Template Haskell backends to the Alex lexer
generator and the Happy parser generator respectively. Usage is something
like this:

{-# Language QuasiQuotes #-}
module LexParse where

import Text.Alex.Quote
import Text.Happy.Quote

compileAlex [$alex|

compileHappy [$happy|

With a bit of luck, the module will contain everything that alex and happy
would generate from these scripts. I say with a bit of luck because these
libraries haven't really been tested except on a few auto-generated
alex/happy scripts (specifically those produced by the BNF Converter).


* The libraries depend on haskell-src-meta to parse the output of alex/happy
and translate it to TH. This means that the libraries are
only compatible with lexers and parsers that don't generate code outside the
scope of this library.

* Currently the libraries contain copies of most of the alex/happy source
code, hopefully in the future the alex/happy packages can expose a few
modules as libraries or the core of alex/happy can be factored out into a
third library (used by both these libraries and the programs).

Best regards
Jonas Duregård
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20100922/361c0a8e/attachment.html

More information about the Haskell-Cafe mailing list