Documentation

Lean.Meta.Match.MatchEqs

def Lean.Meta.Match.mkAppDiscrEqs (alt : Expr) (heqs : Array Expr) (numDiscrEqs : Nat) :

Given an application of an matcher arm alt that is expecting the numDiscrEqs, and an array of discr = pattern equalities (one for each discriminant), apply those that are expected by the alternative.

Equations
Instances For
    def Lean.Meta.Match.proveCondEqThm (matchDeclName : Name) (type : Expr) (heqPos heqNum : Nat := 0) :

    Helper method for proving a conditional equational theorem associated with an alternative of the match-eliminator matchDeclName. type contains the type of the theorem.

    The heqPos/heqNum arguments indicate that these hypotheses are Eq/HEq hypotheses to substitute first; this is used for the generalized match equations.

    Equations
    • One or more equations did not get rendered due to their size.
    Instances For
      @[export lean_get_match_equations_for]
      Equations
      • One or more equations did not get rendered due to their size.
      Instances For
        @[export lean_get_congr_match_equation_for]
        def Lean.Meta.Match.genMatchCongrEqnImpl (matchDeclName : Name) (altIdx : Nat) :

        Generates the congruence equation of the alternative altIdx of the given match auxiliary declaration, and returns its name. See realizeMatchCongrEqn.

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          @[export lean_get_congr_match_equations_for]

          Generates the congruence equations of all alternatives of the given match auxiliary declaration, and returns their names. See realizeMatchCongrEqn.

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