The package gll provides generalised top-down parsing according to the (R)GLL parsing algorithm [Scott and Johnstone 2016].
The user can either invoke the GLL
parser directly by importing
GLL.Parser and providing a
value of the Grammar datatype in (exported by
Alternatively, the user can import
GLL.Combinators to write combinator expressions
from which a grammar of the required form is extracted.
The combinators enable applying arbitrary semantic actions to parse results.
The documentation of the respective packages provides more information.
The main motivation for this package is the development of Domain Specific Languages (DSLs). More specifically: designing DSLs with minimal differences between between abstract and concrete syntax (abstract syntax is often ambiguous).
Please email any questions, comments and suggestions to the maintainer.
+ export maximumPivots and maximumPivotAtNt
0.3.0.8 -> 0.3.0.9
+ include bit of the input string when showing an error message (without whitespace)
+ exporting <multiple/some/many>SepBy2
+ exporting within, parens, braces, brackets, angles, quotes and dquotes
+ added character literals to Token type
+ exporting <:=
+ <<<**> and <**>>> for shortest and longest match, respectively
defined some/many and variants using <**>>> and <<<**>
disambiguation remains very experimental
0.3.0.9 -> 0.3.0.10
+ exporting chooses
0.3.0.10 -> 0.3.0.11
+ parse option for disabling select test (lookahead)
0.3.0.11 -> 0.4.0.1
+ replaced parser by reduced descriptor GLL (RGLL)
+ renamed GLL.Types.Grammar to GLL.Types.Derivations
+ renamed GLL.Types.Abstract to GLL.Types.Grammar
+ exporting GLL.Types.Grammar, GLL.Types.Derivations, GLL.Combinators.Options, GLL.Combinators.Memoisation, GLL.Flags
0.4.0.1 -> 0.4.0.2
+ generalised `within`
+ different whitespace and comment handling in predefined lexer
+ predefined lexer handles (nested) comment-blocks
0.4.0.2 -> 0.4.0.3
M added hex, octal and binary representation to integer literals
+ added float literals
+ exporting `preferably` and `reluctantly`
M renamed `rassoc` to shortest_match
M renamed `lassoc` to longest_match
- removed `assoc`
+ version of `chooses` that is left-biased (w.r.t. alternatives)
+ generalised arguments of longest_match and shortest_match to IsAltExpr
+ exporting `optionalWithDef`
0.4.0.3 -> 0.4.0.4
+ `chooses` cannot be given an empty list (runtime error)
+ updated `base` dependency