The Mathlib Handbook

The volumes of the handbook are not written yet. This site shows the map of Mathlib that they will follow, at Mathlib 4472534b60.

The areas / V01. The language of Mathlib

Mathlib.Lean.FoldEnvironment

3 declarations. Mathlib docs · Source

abbrev Lean.Meta.FoldDeclErrorRef E1 #

Type

An IO.Ref that keeps track of any errors that could have been thrown by act when folding over the constants in the environment.

def Lean.Meta.foldImportedDecls E1 #

{α : Type} →
  α →
    Lean.Meta.Config →
      (α → Lean.Name → Lean.ConstantInfo → Lean.MetaM α) →
        optParam ℕ 5000 → Lean.CoreM (Array (Task (Except Lean.Exception α)) × Lean.Meta.FoldDeclErrorRef)

Fold through all imported constants using act. This uses parallelism, with each thread independently folding over a subset of modules. The array of tasks is returned, so this function typically returns before all tasks have finished. The results can then be combined using Array.foldl.

def Lean.Meta.foldCurrFileDecls E1 #

{α : Type} →
  α →
    Lean.Meta.Config → (α → Lean.Name → Lean.ConstantInfo → Lean.MetaM α) → Lean.CoreM (α × Lean.Meta.FoldDeclErrorRef)

Fold through all constants of the current file using act.