HORIZON HASKELLDocslts/ghc-10.0.xfc4e5982026-10-11Search names, modules, packages, or :: a typeCtrl K

GHC 10.0.0.20260917 · lts/ghc-10.0.x · fc4e598 · 2026-10-11

ModuleAgda-2.8.0.2Haskell2010

Agda.Termination.RecCheck

Checking for recursion:

  • We detect truly (co)recursive definitions by computing the dependency graph and checking for cycles.

  • This is inexpensive and let us skip the termination check when there's no (co)recursion

Original contribution by Andrea Vezzosi (sanzhiyan). This implementation by Andreas.

  • 1 type
  • 2 values
  • PackageAgda-2.8.0.2
  • Exports3
  • LanguageHaskell2010
  • LicenceMIT
  • SourceRecCheck.hs
typetype MutualNames = Set QName
#

The mutual block we are checking.

The functions are numbered according to their order of appearance in this set.

valuerecursive :: Set QName -> TCM [MutualNames]
#

Given a list of formally mutually recursive functions, check for actual recursive calls in the bodies of these functions. Returns the actually recursive functions as strongly connected components.

As a side effect, update the clauseRecursive field in the clauses belonging to the given functions.