Safe Haskell | None |
---|
- data ExprView e
- class HasRange e => IsExpr e where
- exprView :: e -> ExprView e
- unExprView :: ExprView e -> e
- partP :: IsExpr e => [Name] -> RawName -> ReadP e Range
- binop :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e (e -> e -> e)
- preop :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e (e -> e)
- postop :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e (e -> e)
- opP :: IsExpr e => ReadP e e -> NewNotation -> ReadP e (NewNotation, Range, [e])
- rebuild :: forall e. IsExpr e => NewNotation -> Range -> [e] -> e
- rebuildBinding :: IsExpr e => ExprView e -> LamBinding
- infixP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e e
- nonfixP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e e
- prefixP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e e
- postfixP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e e
- infixlP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e e
- infixrP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e e
- argsP :: IsExpr e => ReadP e e -> ReadP e [NamedArg e]
- appP :: IsExpr e => ReadP e e -> ReadP e [NamedArg e] -> ReadP e e
- atomP :: IsExpr e => (QName -> Bool) -> ReadP e e
Documentation
Parser combinators
partP :: IsExpr e => [Name] -> RawName -> ReadP e RangeSource
Parse a specific identifier as a NamePart
opP :: IsExpr e => ReadP e e -> NewNotation -> ReadP e (NewNotation, Range, [e])Source
Parse the operator part of the given syntax. holes at beginning and end are IGNORED.
rebuild :: forall e. IsExpr e => NewNotation -> Range -> [e] -> eSource
Given a name with a syntax spec, and a list of parsed expressions fitting it, rebuild the expression.
rebuildBinding :: IsExpr e => ExprView e -> LamBindingSource
infixP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e eSource
Parse using the appropriate fixity, given a parser parsing the operator part, the name of the operator, and a parser of subexpressions.
nonfixP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e eSource
Parse using the appropriate fixity, given a parser parsing the operator part, the name of the operator, and a parser of subexpressions.
prefixP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e eSource
Parse using the appropriate fixity, given a parser parsing the operator part, the name of the operator, and a parser of subexpressions.
postfixP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e eSource
Parse using the appropriate fixity, given a parser parsing the operator part, the name of the operator, and a parser of subexpressions.
infixlP :: IsExpr e => ReadP e (NewNotation, Range, [e]) -> ReadP e e -> ReadP e eSource
Parse using the appropriate fixity, given a parser parsing the operator part, the name of the operator, and a parser of subexpressions.