penntreebank-megaparsec-0.2.0: Parser combinators for trees in the Penn Treebank format

Copyright(c) 2020 Nori Hayashi
LicenseBSD3
MaintainerNori Hayashi <net@hayashi-lin.net>
Stabilityexperimental
Portabilityportable
Safe HaskellNone
LanguageHaskell2010

Data.Tree.Parser.Penn.Megaparsec.Internal

Description

Language : Haskell2010

Synopsis

Documentation

class Stream str => ParsableAsTerm str term where Source #

A type class for node label types term data of which can be obtained by parsing a stream of type str that is safely carved by the tree parser pTree containing no spaces and parenthese.

Methods

pNonTerm :: Ord err => ParsecT err str m term Source #

A parser for non-terminal node labels. Empty inputs are expected.

pTerm :: Ord err => ParsecT err str m term Source #

A parser for terminal node labels. Empty inputs are not expected.

Instances
(Stream str, Tokens str ~ term) => ParsableAsTerm str term Source # 
Instance details

Defined in Data.Tree.Parser.Penn.Megaparsec.Internal

Methods

pNonTerm :: Ord err => ParsecT err str m term Source #

pTerm :: Ord err => ParsecT err str m term Source #