Cached checkDecl
ModuleAgda-2.7.0.1Haskell2010
Agda.TypeChecking.Rules.Decl
- 2 types
- 1 class
- 31 values
- PackageAgda-2.7.0.1
- Exports34
- LanguageHaskell2010
- LicenceMIT
- SourceDecl.hs
Type check a sequence of declarations.
Type check a single declaration.
Check if there is a inferred eta record type in the mutual block. If yes, repeat the record pattern translation for all function definitions in the block. This is necessary since the original record pattern translation will have skipped record patterns of the new record types (as eta was off for them). See issue #2308 (and #2197).
Run a reflected TCM computatation expected to define a given list of names.
Instantiate all metas in Definition associated to QName. Makes sense after freezing metas. Some checks, like free variable analysis, are not in TCM, so they will be more precise (see issue 1099) after meta instantiation. Precondition: name has been added to signature already.
Instances1Eq
Eq HighlightModuleContentsDefined in Agda-2.7.0.1 · Agda.TypeChecking.Rules.Decl
Highlight a declaration. Called after checking a mutual block (to ensure we have the right definitions for all names). For modules inside mutual blocks we haven't highlighted their contents, but for modules not in a mutual block we have. Hence the flag.
Termination check a declaration.
Check a set of mutual names for positivity.
Check that all coinductive records are actually recursive. (Otherwise, one can implement invalid recursion schemes just like for the old coinduction.)
Check a set of mutual names for constructor-headedness.
Check a set of mutual names for projection likeness.
Only a single, non-abstract function can be projection-like. Making an abstract function projection-like would break the invariant that the type of the principle argument of a projection-like function is always inferable.
Freeze metas created by given computation if in abstract mode.
Type check an axiom.
Data and record type signatures need to remember the generalized parameters for when checking the corresponding definition, so for these we pass in the parameter telescope separately.
Type check a primitive function declaration.
Check a pragma.
Type check a bunch of mutual inductive recursive definitions.
All definitions which have so far been assigned to the given mutual block are returned.
Type check the type signature of an inductive or recursive definition.
Type check a module.
checkModuleArity Helper for checkSectionApplication.
Matches the arguments of the module application with the module parameters.
Returns the remaining module parameters as an open telescope. Warning: the returned telescope is not the final result, an actual instantiation of the parameters does not occur.
checkSectionApplication :: ModuleInfo-> ErasedShould "everything" be treated as erased?
-> ModuleNameName
m1of module defined by the module macro.-> ModuleApplicationThe module macro
λ tel → m2 args.-> ScopeCopyInfoImported names and modules
-> ImportDirective-> TCM ()
Check an application of a section.
checkSectionApplication' :: ModuleInfo-> Erased-> ModuleNameName
m1of module defined by the module macro.-> ModuleApplicationThe module macro
λ tel → m2 args.-> ScopeCopyInfoImported names and modules
-> TCM ()
Check an application of a section. (Do not invoke this procedure directly, use checkSectionApplication.)
Checks that open public is not used in hard compile-time mode.
Debugging
2 declarationsInstances1ShowHead
ShowHead DeclarationDefined in Agda-2.7.0.1 · Agda.TypeChecking.Rules.Decl