Documentation

Lean.Meta.Sym.DSimp.Rewrite

Rewriting with rfl-theorems in Sym.dsimp #

Sym.dsimp reuses the Sym.simp theorems, but only the ones proved by rfl, since a rewrite step must hold by definitional equality. Theorems with hypotheses are never applied: there is no discharger, and the instantiated hypotheses would have to be part of a proof term. Definitions are unfolded by unfold instead of their equational theorems, which are rarely rfl-theorems.

Tries to rewrite e using thm.

Instances For

    Rewrites e using the first applicable theorem in thms. The fallback theorems (Theorem.fallback) are tried only when no other theorem rewrites e.

    Instances For

      The rfl-theorems and the definitions to unfold contributed by Sym.dsimp parameters.

      Instances For
        def Lean.Meta.Sym.DSimp.Decls.add (decls : Decls) (declName : Name) :

        Adds the declaration declName to decls. A theorem must be proved by rfl. A definition is unfolded (see unfold) under the same conditions as in Meta.simp (Simp.unfoldEvenWithEqns), and contributes its equational theorems proved by rfl. See also Sym.Simp.getSimpTheoremNames.

        Instances For

          The dsimproc unfolding the definitions and rewriting with the theorems in decls.

          Instances For