parser-combinators

Lightweight package providing commonly useful parser combinators

https://github.com/mrkkrp/parser-combinators

Version on this page:1.2.1
LTS Haskell 22.39:1.3.0@rev:1
Stackage Nightly 2024-10-31:1.3.0@rev:1
Latest on Hackage:1.3.0@rev:1

See all snapshots parser-combinators appears in

Maintained by Mark Karpov
This version can be pinned in stack with:parser-combinators-1.2.1@sha256:16c3490e007ec10b1255a2b36fb483d000156d555269107131241d9e0fa96412,1788

Parser combinators

License BSD3 Hackage Stackage Nightly Stackage LTS Build Status

The package provides common parser combinators defined in terms of Applicative and Alternative without any dependencies but base. There are also more efficient versions of the combinators defined in terms of Monad and MonadPlus.

Contribution

Issues, bugs, and questions may be reported in the GitHub issue tracker for this project.

Pull requests are also welcome.

License

Copyright © 2017–present Mark Karpov

Distributed under BSD 3 clause license.

Changes

Parser combinators 1.2.1

  • The tests in parser-combinators-tests now work with Megaparsec 8.

  • Dropped support for GHC 8.2.

Parser combinators 1.2.0

  • Added manyTill_ and someTill_ combinators which work like the older manyTill and someTill except they also return the result of the end parser.

  • Dropped support for GHC 8.0.

Parser combinators 1.1.0

  • Added support for ternary operators; see TernR in Control.Monad.Combinators.Expr.

Parser combinators 1.0.3

  • Dropped support for GHC 7.10.

  • Added a test suite as a separate package called parser-combinators-tests.

Parser combinators 1.0.2

  • Defined liftA2 for Permutation manually. The new definition should be more efficient.

  • Made inner Maybe field in Permutation strict.

Parser combinators 1.0.1

  • Cosmetic changes in the source code.

Parser combinators 1.0.0

  • Added the Control.Monad.Combinators.Expr module.

  • Dropped the compatibility operators (<$$>), (<$?>), (<||>), and (<|?>) from Control.Applicative.Permutations.

  • Dropped support for GHCs older than 7.10.

Parser combinators 0.4.0

  • Improved the documentation.

  • Re-exported Control.Applicative.empty from Control.Applicative.Combinators.

  • Added the Control.Monad.Combinators and Control.Monad.Combinators.NonEmpty modules which contain more efficient versions of the combinators from Control.Applicative.Combinators and Control.Applicative.Combinators.NonEmpty respectively.

Parser combinators 0.3.0

  • Added the skipCount combinator.

  • Improved algorithmic efficiency of the count' combinator.

Parser combinators 0.2.1

  • Removed the byte order marking at the beginning of the Control.Applicative.Permutations module.

Parser combinators 0.2.0

  • Added Control.Applicative.Combinators.NonEmpty module that exports non-empty list versions of combinators that cannot return empty lists.

  • Added Control.Applicative.Permutations module that provides generalized permutation parser combinators.

Parser combinators 0.1.0

  • Initial release.