Safe Haskell | None |
---|
Core language parser.
- type Parser n a = Parser (Tok n) a
- data Context = Context {}
- contextOfProfile :: Profile n -> Context
- pModule :: (Ord n, Pretty n) => Context -> Parser n (Module SourcePos n)
- pExp :: Ord n => Context -> Parser n (Exp SourcePos n)
- pExpApp :: Ord n => Context -> Parser n (Exp SourcePos n)
- pExpAtom :: Ord n => Context -> Parser n (Exp SourcePos n)
- pType :: Ord n => Context -> Parser n (Type n)
- pTypeApp :: Ord n => Context -> Parser n (Type n)
- pTypeAtom :: Ord n => Context -> Parser n (Type n)
- pWitness :: Ord n => Context -> Parser n (Witness SourcePos n)
- pWitnessApp :: Ord n => Context -> Parser n (Witness SourcePos n)
- pWitnessAtom :: Ord n => Context -> Parser n (Witness SourcePos n)
- pCon :: Parser n n
- pLit :: Parser n n
- pBinder :: Ord n => Parser n (Binder n)
- pIndex :: Parser n Int
- pVar :: Parser n n
- pName :: Parser n n
- pTok :: TokAtom -> Parser n ()
- pTokAs :: TokAtom -> a -> Parser n a
Documentation
Configuration and information from the context. Used for context sensitive parsing.
contextOfProfile :: Profile n -> ContextSource
Slurp an initital Context from a Profile
Modules
Expressions
pExpAtom :: Ord n => Context -> Parser n (Exp SourcePos n)Source
Parse a variable, constructor or parenthesised expression.
Types
pTypeAtom :: Ord n => Context -> Parser n (Type n)Source
Parse a variable, constructor or parenthesised type.
Witnesses
pWitnessAtom :: Ord n => Context -> Parser n (Witness SourcePos n)Source
Parse a variable, constructor or parenthesised witness.