BNFC-meta-0.4.0.3: Deriving Parsers and Quasi-Quoters from BNF Grammars

Safe HaskellNone
LanguageHaskell98

Language.LBNF.Compiletime

Contents

Description

Contains things needed by BNFC-meta language definitions and by the code generated from those. Typical users don't need to browse this module.

Synopsis

Happy and Alex

data HappyStk a :: * -> * infixr 9

Constructors

HappyStk a (HappyStk a) infixr 9 

data Posn Source

Constructors

Pn !Int !Int !Int 

Instances

ord :: Char -> Int

The fromEnum method restricted to the type Char.

listArray :: Ix i => (i, i) -> [e] -> Array i e

Construct an array from a pair of bounds and a list of values in index order.

(!) :: Ix i => Array i e -> i -> e infixl 9

The value at the given index in an array.

data Array i e :: * -> * -> *

The type of immutable non-strict (boxed) arrays with indices in i and elements in e.

Instances

Ix i => Functor (Array i) 
(Ix i, Eq e) => Eq (Array i e) 
(Typeable * a, Data a, Data b, Ix a) => Data (Array a b) 
(Ix i, Ord e) => Ord (Array i e) 
(Ix a, Read a, Read b) => Read (Array a b) 
(Ix a, Show a, Show b) => Show (Array a b) 
Typeable (* -> * -> *) Array 

Pretty printing

prPrec :: Int -> Int -> Doc -> Doc Source

newtype PrintPlain Source

Constructors

MkPrintPlain String 

Instances

Quasi quoting

errq :: (String -> a) -> ParseMonad a -> Q a Source

data Q a :: * -> *

class Lift t where

Methods

lift :: t -> Q Exp

class Literal a where Source

Methods

lit :: a -> Lit Source

class IsChar a where Source

Methods

toChar :: a -> Char Source

Instances

Helper functions for defining Anti-quotation