Documentation

Lean.Meta.Sorry

Utilities for creating and recognizing sorry #

This module develops material for creating and recognizing sorryAx terms that encode originating source positions. There are three orthogonal configurations for sorries:

Returns sorryAx type synthetic. Recall that synthetic is true if this sorry is from an error.

See also Lean.Meta.mkLabeledSorry, for creating a sorry that is labeled or unique.

Equations
Instances For
    • Records the origin module name, logical source position, and LSP range for the sorry. The logical source position is used when displaying the sorry when the pp.sorrySource option is true, and the LSP range is used for "go to definition" in the Infoview.

    Instances For
      Equations
      • One or more equations did not get rendered due to their size.
      Instances For
        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          def Lean.Meta.mkLabeledSorry (type : Lean.Expr) (synthetic unique : Bool) :

          Constructs a sorryAx.

          • If the current ref has a source position, then creates a labeled sorry. This supports "go to definition" in the InfoView and pretty printing a source position when the pp.sorrySource option is true.
          • If synthetic is true, then the sorry is regarded as being generated by the elaborator. The caller should ensure that there is an associated error logged.
          • If unique is true, the sorry is unique, in the sense that it is not defeq to any other sorry created by mkLabeledSorry.
          Equations
          • One or more equations did not get rendered due to their size.
          Instances For

            Returns a SorryLabelView if e is an application of an expression returned by mkLabeledSorry. If it is, then the sorry takes the first three arguments, and the tag is at argument 3.

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For