Agda-2.5.2: A dependently typed functional programming language and proof assistant

Safe Haskell | None
Language | Haskell2010

Agda.Syntax.Concrete.Operators

Description

The parser doesn't know about operators and parses everything as normal function application. This module contains the functions that parses the operators properly. For a stand-alone implementation of this see `src/prototyping/mixfix/old`.

It also contains the function that puts parenthesis back given the precedence of the context.

Synopsis

- parseApplication :: [Expr] -> ScopeM Expr
- parseModuleApplication :: Expr -> ScopeM (QName, [NamedArg Expr])
- parseLHS :: QName -> Pattern -> ScopeM LHSCore
- parsePattern :: Pattern -> ScopeM Pattern
- parsePatternSyn :: Pattern -> ScopeM Pattern

# Documentation

parseApplication :: [Expr] -> ScopeM Expr #

Parse a list of expressions into an application.

parseModuleApplication :: Expr -> ScopeM (QName, [NamedArg Expr]) #

Parse an expression into a module application (an identifier plus a list of arguments).

parseLHS :: QName -> Pattern -> ScopeM LHSCore #

Parses a left-hand side, and makes sure that it defined the expected name.

parsePattern :: Pattern -> ScopeM Pattern #

Parses a pattern.

parsePatternSyn :: Pattern -> ScopeM Pattern #