par
parzec
npm i parzec
par

parzec

Parser combinators for TypeScript

by Tommi Johtela

1.0.2 (see all)License:MPL-2.0TypeScript:Not Found
npm i parzec
Readme

Parser Combinators for Typescript

Build status Version

Parzec is a parser combinator library adapted from Haskell's famous Parsec library. A parser combinator library consist of higher order functions which make it easy to build recursive descent parsers. Parsers composed from Parzec's combinators can recognize languages in the PEG class of grammars. PEG grammars can be context-sensitive, so the parsers have infinite lookahead and backtracking capabilities.

Parzec also supports efficient parsing of LL(1) grammars by enabling the backtracking only when a special combinator is used. Also, to improve performance, some combinators have been inlined rather than built from lower level combinators.

Parzec's input is represented by an abstract interface. Consequently, the parsers' input can be anything from simple strings to files, or even tokenized data streams. Parzec includes functionality to create lexical analyzers or lexers from regular expressions. The lexer converts input strings into tokens, and makes the parsing simpler and more efficient.

Downloads/wk

121

GitHub Stars

11

LAST COMMIT

1yr ago

MAINTAINERS

1

CONTRIBUTORS

1

OPEN ISSUES

0

OPEN PRs

2
VersionTagPublished
1.0.2
latest
1yr ago
No alternatives found
No tutorials found
Add a tutorial
No dependencies found

Rate & Review

100
No reviews found
Be the first to rate