gll-0.4.1.0: GLL parser with simple combinator interface
Safe HaskellSafe-Inferred
LanguageHaskell2010

GLL.Flags

Synopsis

Documentation

data Flags Source #

Flags to influence the behaviour of the parser.

defaultFlags :: Flags Source #

The default flags: * Do not add symbol nodes to the SPPF. * Do not add intermediate nodes to the SPPF. * Do not add edges to the SPPF. * Flexible binarisation. * The three furthest discoveries of a token mismatch are reported. * Select tests are performed.

runOptions :: ParseOptions -> Flags Source #

Execute the given Options in left-to-right order on defaultFlags.

type ParseOption = Flags -> Flags Source #

An option updates the current set of Flags.

type ParseOptions = [ParseOption] Source #

A list of ParserOptions

fullSPPF :: ParseOption Source #

Create the SPPF with all nodes and edges, not necessarily strictly binarised.

allNodes :: ParseOption Source #

Create all nodes, but no edges between nodes.

packedNodesOnly :: ParseOption Source #

Create packed-nodes only.

strictBinarisation :: ParseOption Source #

Fully binarise the SPPF, resulting in a larger SPPF and possibly slower runtimes. When this flag is on, packed nodes can only have a single symbol node child or one intermediate node child and one symbol node child. With the flag disabled a packed node can have two symbol node children.

maximumErrors :: Int -> ParseOption Source #

Set the maximum number of errors shown in case of an unsuccessful parse.

noSelectTest :: ParseOption Source #

Turn of select tests. Disables lookahead.