HORIZON HASKELLDocslts/ghc-9.10.xc74966e2026-09-27Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · c74966e · 2026-09-27

ModuleAgda-2.7.0.1Haskell2010

Agda.Syntax.Scope.Monad

The scope monad with operations.

  • 5 types
  • 68 values
  • PackageAgda-2.7.0.1
  • Exports73
  • LanguageHaskell2010
  • LicenceMIT
  • SourceMonad.hs

The scope checking monad

4 declarations
typetype ScopeM = TCM
#

To simplify interaction between scope checking and type checking (in particular when chasing imports), we use the same monad.

General operations

29 declarations
valueoutsideLocalVars :: Int -> ScopeM a -> ScopeM a
#

Run a computation outside some number of local variables and add them back afterwards. This lets you bind variables in the middle of the context and is used when binding generalizable variables (#3735).

valuebindVarsToBind :: ScopeM ()
#

After collecting some variable names in the scopeVarsToBind, bind them all simultaneously.

Names

5 declarations

Create a concrete name that is not yet in scope. | NOTE: See chooseName in Agda.Syntax.Translation.AbstractToConcrete for similar logic. | NOTE: See withName in Agda.Syntax.Translation.ReflectedToAbstract for similar logic.

Resolving names

9 declarations

Look up the abstract name corresponding to a concrete name of a certain kind and/or from a given set of names. Sometimes we know already that we are dealing with a constructor or pattern synonym (e.g. when we have parsed a pattern). Then, we can ignore conflicting definitions of that name of a different kind. (See issue 822.)

Binding names

8 declarations

Module manipulation operations

6 declarations

Import directives

8 declarations

Opening a module

4 declarations

Orphan instances

1 instance