parsnip: A fast, minimal parser
A fast, minimal parser.
parsnip parses null-terminated input strings with an absolute minimum of
internal state. It copies the input to a c string and works its way through
hand-over-hand with just an
Addr# as the internal state.
reflection-like tricks to lift the input
ByteString into a
constraint that is then passed to just the combinators that need access
to it to compute position, snip out slices of the original, or ask the
number of bytes remaining, but none of the monadic combinators nor simple
eof predicates need access to this information.
Because of the null-termination, we can't assume that we can handle binary inputs, but this works well for text-based source languages.
[Skip to Readme]
|Dependencies||attoparsec, base (>=4.15 && <5), bytestring, containers, data-default, ghc-prim, primitive [details]|
|License||(BSD-2-Clause OR Apache-2.0)|
|Copyright||Copyright (c) 2019-2021 Edward Kmett|
|Maintainer||Edward Kmett <email@example.com>|
|Source repo||head: git clone https://github.com/ekmett/codex(parsnip)|
|Uploaded||by EdwardKmett at 2021-03-24T01:32:48Z|
|Downloads||31 total (4 in the last 30 days)|
|Rating||(no votes yet) [estimated by Bayesian average]|
Docs uploaded by user
Build status unknown [no reports yet]
For package maintainers and hackage trustees