Idris.Delaborate

idris-1.3.4: Functional Programming Language with Dependent Types

License | BSD3
Maintainer | The Idris Community.
Safe Haskell | None
Language | Haskell2010

Idris.Delaborate

Description

Synopsis

- annName :: Name -> Doc OutputAnnotation
- bugaddr :: String
- delab :: IState -> Term -> PTerm
- delabWithEnv :: IState -> [(Name, Type)] -> Term -> PTerm
- delabDirect :: IState -> Term -> PTerm
- delab' :: IState -> Term -> Bool -> Bool -> PTerm
- delabMV :: IState -> Term -> PTerm
- delabSugared :: IState -> Term -> PTerm
- delabTy :: IState -> Name -> PTerm
- delabTy' :: IState -> [PArg] -> [(Name, Type)] -> Term -> Bool -> Bool -> Bool -> PTerm
- fancifyAnnots :: IState -> Bool -> OutputAnnotation -> OutputAnnotation
- pprintDelab :: IState -> Term -> Doc OutputAnnotation
- pprintNoDelab :: IState -> Term -> Doc OutputAnnotation
- pprintDelabTy' :: IState -> Name -> Term -> Doc OutputAnnotation
- pprintDelabTy :: IState -> Name -> Doc OutputAnnotation
- pprintErr :: IState -> Err -> Doc OutputAnnotation
- resugar :: IState -> PTerm -> PTerm

# Documentation

annName :: Name -> Doc OutputAnnotation #

bugaddr :: String #

delab :: IState -> Term -> PTerm #

Delaborate a term without resugaring

delabWithEnv :: IState -> [(Name, Type)] -> Term -> PTerm #

delabDirect :: IState -> Term -> PTerm #

Delaborate a term directly, leaving case applications as they are. We need this for interactive case splitting, where we need access to the underlying function in a delaborated form, to generate the right patterns

delab' :: IState -> Term -> Bool -> Bool -> PTerm #

delabMV :: IState -> Term -> PTerm #

delabSugared :: IState -> Term -> PTerm #

Delaborate and resugar a term

delabTy :: IState -> Name -> PTerm #

delabTy' #

Arguments

:: IState |
-> [PArg] | implicit arguments to type, if any
-> [(Name, Type)] | Names and types in environment (for properly hiding scoped implicits)
-> Term |
-> Bool | use full names
-> Bool | Don't treat metavariables specially
-> Bool | resugar cases
-> PTerm |

fancifyAnnots :: IState -> Bool -> OutputAnnotation -> OutputAnnotation #

Add extra metadata to an output annotation, optionally marking metavariables.

pprintDelab :: IState -> Term -> Doc OutputAnnotation #

Pretty-print a core term using delaboration

pprintNoDelab :: IState -> Term -> Doc OutputAnnotation #

pprintDelabTy' :: IState -> Name -> Term -> Doc OutputAnnotation #

pprintDelabTy :: IState -> Name -> Doc OutputAnnotation #

Pretty-print the type of some name

pprintErr :: IState -> Err -> Doc OutputAnnotation #

resugar :: IState -> PTerm -> PTerm #

Re-add syntactic sugar in a term