| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
BNFC.Abs
Description
The abstract syntax of language BNFC.
Synopsis
- data Grammar = Grammar [Def]
- data Def
- = Rule Label Cat [Item]
- | Comment String
- | Comments String String
- | Internal Label Cat [Item]
- | Token Identifier Reg
- | PosToken Identifier Reg
- | Entryp [Cat]
- | Separator MinimumSize Cat String
- | Terminator MinimumSize Cat String
- | Delimiters Cat String String Separation MinimumSize
- | Coercions Identifier Integer
- | Rules Identifier [RHS]
- | Function Identifier [Arg] Exp
- | Layout [String]
- | LayoutStop [String]
- | LayoutTop
- data Item
- data Cat
- data Label
- data Arg = Arg Identifier
- data Separation
- data Exp
- data RHS = RHS [Item]
- data MinimumSize
- data Reg
- newtype Identifier = Identifier ((Int, Int), String)
- type BNFC'Position = Maybe (Int, Int)
- pattern BNFC'NoPosition :: BNFC'Position
- pattern BNFC'Position :: Int -> Int -> BNFC'Position
- class HasPosition a where
- hasPosition :: a -> BNFC'Position
Documentation
Constructors
| Rule Label Cat [Item] | |
| Comment String | |
| Comments String String | |
| Internal Label Cat [Item] | |
| Token Identifier Reg | |
| PosToken Identifier Reg | |
| Entryp [Cat] | |
| Separator MinimumSize Cat String | |
| Terminator MinimumSize Cat String | |
| Delimiters Cat String String Separation MinimumSize | |
| Coercions Identifier Integer | |
| Rules Identifier [RHS] | |
| Function Identifier [Arg] Exp | |
| Layout [String] | |
| LayoutStop [String] | |
| LayoutTop |
Constructors
| ListCat Cat | |
| IdCat Identifier |
Constructors
| Arg Identifier |
data Separation Source #
Instances
| Print Separation Source # | |
Defined in BNFC.Print Methods prt :: Int -> Separation -> Doc Source # | |
| Read Separation Source # | |
Defined in BNFC.Abs Methods readsPrec :: Int -> ReadS Separation readList :: ReadS [Separation] readPrec :: ReadPrec Separation readListPrec :: ReadPrec [Separation] | |
| Show Separation Source # | |
Defined in BNFC.Abs Methods showsPrec :: Int -> Separation -> ShowS show :: Separation -> String showList :: [Separation] -> ShowS | |
| Eq Separation Source # | |
Defined in BNFC.Abs | |
| Ord Separation Source # | |
Defined in BNFC.Abs Methods compare :: Separation -> Separation -> Ordering (<) :: Separation -> Separation -> Bool (<=) :: Separation -> Separation -> Bool (>) :: Separation -> Separation -> Bool (>=) :: Separation -> Separation -> Bool max :: Separation -> Separation -> Separation min :: Separation -> Separation -> Separation | |
Constructors
| Cons Exp Exp | |
| App Identifier [Exp] | |
| Var Identifier | |
| LitInt Integer | |
| LitChar Char | |
| LitString String | |
| LitDouble Double | |
| List [Exp] |
data MinimumSize Source #
Instances
| Print MinimumSize Source # | |
Defined in BNFC.Print Methods prt :: Int -> MinimumSize -> Doc Source # | |
| Read MinimumSize Source # | |
Defined in BNFC.Abs Methods readsPrec :: Int -> ReadS MinimumSize readList :: ReadS [MinimumSize] readPrec :: ReadPrec MinimumSize readListPrec :: ReadPrec [MinimumSize] | |
| Show MinimumSize Source # | |
Defined in BNFC.Abs Methods showsPrec :: Int -> MinimumSize -> ShowS show :: MinimumSize -> String showList :: [MinimumSize] -> ShowS | |
| Eq MinimumSize Source # | |
Defined in BNFC.Abs | |
| Ord MinimumSize Source # | |
Defined in BNFC.Abs Methods compare :: MinimumSize -> MinimumSize -> Ordering (<) :: MinimumSize -> MinimumSize -> Bool (<=) :: MinimumSize -> MinimumSize -> Bool (>) :: MinimumSize -> MinimumSize -> Bool (>=) :: MinimumSize -> MinimumSize -> Bool max :: MinimumSize -> MinimumSize -> MinimumSize min :: MinimumSize -> MinimumSize -> MinimumSize | |
Constructors
| RAlt Reg Reg | |
| RMinus Reg Reg | |
| RSeq Reg Reg | |
| RStar Reg | |
| RPlus Reg | |
| ROpt Reg | |
| REps | |
| RChar Char | |
| RAlts String | |
| RSeqs String | |
| RDigit | |
| RLetter | |
| RUpper | |
| RLower | |
| RAny |
newtype Identifier Source #
Constructors
| Identifier ((Int, Int), String) |
Instances
| HasPosition Identifier Source # | |
Defined in BNFC.Abs Methods | |
| Print Identifier Source # | |
Defined in BNFC.Print Methods prt :: Int -> Identifier -> Doc Source # | |
| Read Identifier Source # | |
Defined in BNFC.Abs Methods readsPrec :: Int -> ReadS Identifier readList :: ReadS [Identifier] readPrec :: ReadPrec Identifier readListPrec :: ReadPrec [Identifier] | |
| Show Identifier Source # | |
Defined in BNFC.Abs Methods showsPrec :: Int -> Identifier -> ShowS show :: Identifier -> String showList :: [Identifier] -> ShowS | |
| Eq Identifier Source # | |
Defined in BNFC.Abs | |
| Ord Identifier Source # | |
Defined in BNFC.Abs Methods compare :: Identifier -> Identifier -> Ordering (<) :: Identifier -> Identifier -> Bool (<=) :: Identifier -> Identifier -> Bool (>) :: Identifier -> Identifier -> Bool (>=) :: Identifier -> Identifier -> Bool max :: Identifier -> Identifier -> Identifier min :: Identifier -> Identifier -> Identifier | |
type BNFC'Position = Maybe (Int, Int) Source #
Start position (line, column) of something.
pattern BNFC'NoPosition :: BNFC'Position Source #
pattern BNFC'Position :: Int -> Int -> BNFC'Position Source #
class HasPosition a where Source #
Get the start position of something.
Methods
hasPosition :: a -> BNFC'Position Source #
Instances
| HasPosition Identifier Source # | |
Defined in BNFC.Abs Methods | |