megaparsec: Monadic parser combinators

[ bsd2, library, parsing ] [ Propose Tags ]

This is industrial-strength monadic parser combinator library. Megaparsec is a fork of Parsec library originally written by Daan Leijen.

Megaparsec is different from Parsec in the following ways:

  • Better error messages. We test our error messages using dense QuickCheck tests. Good error messages are just as important for us as correct return values of our parsers. Megaparsec will be especially useful if you write compiler or interpreter for some language.

  • Some quirks and “buggy features” (as well as plain bugs) of original Parsec are fixed. There is no undocumented surprising stuff in Megaparsec.

  • Better support for Unicode parsing in Text.Megaparsec.Char.

  • Megaparsec has more powerful combinators and can parse languages where indentation matters.

  • Comprehensive QuickCheck test suite covering nearly 100% of our code.

  • We have benchmarks to detect performance regressions.

  • Better documentation, with 100% of functions covered, without typos and obsolete information, with working examples. Megaparsec's documentation is well-structured and doesn't contain things useless to end user.

  • Megaparsec's code is clearer and doesn't contain “magic” found in original Parsec.

  • Megaparsec looks into the future, it does not contain code that serves for compatibility purposes, it also requires more recent version of base.

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

Versions [RSS] 4.0.0, 4.1.0, 4.1.1, 4.2.0, 4.3.0, 4.4.0, 5.0.0, 5.0.1, 5.1.0, 5.1.1, 5.1.2, 5.2.0, 5.3.0, 5.3.1, 6.0.0, 6.0.1, 6.0.2, 6.1.0, 6.1.1, 6.2.0, 6.3.0, 6.4.0, 6.4.1, 6.5.0, 7.0.0, 7.0.1, 7.0.2, 7.0.3, 7.0.4, 7.0.5, 8.0.0, 9.0.0, 9.0.1, 9.1.0, 9.2.0, 9.2.1, 9.2.2, 9.3.0, 9.3.1, 9.4.0, 9.4.1, 9.5.0, 9.6.0, 9.6.1 (info)
Change log CHANGELOG.md
Dependencies base (>=4.8 && <5), bytestring, mtl (>=2 && <3), text (>=0.2 && <1.3), transformers (>=0.4 && <0.5) [details]
License BSD-3-Clause
Author Megaparsec contributors, Paolo Martini <paolo@nemail.it>, Daan Leijen <daan@microsoft.com>
Maintainer Mark Karpov <markkarpov@opmbx.org>
Category Parsing
Home page https://github.com/mrkkrp/megaparsec
Bug tracker https://github.com/mrkkrp/megaparsec/issues
Source repo head: git clone https://github.com/mrkkrp/megaparsec.git
Uploaded by mrkkrp at 2015-09-25T08:06:53Z
Distributions Arch:9.5.0, Debian:8.0.0, Fedora:9.3.1, LTSHaskell:9.5.0, NixOS:9.3.1, Stackage:9.6.1, openSUSE:9.5.0
Reverse Dependencies 272 direct, 421 indirect [details]
Downloads 98296 total (698 in the last 30 days)
Rating 2.75 (votes: 24) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs uploaded by user [build log]
All reported builds failed as of 2015-09-25 [all 1 reports]