Lift and Unlift utilities #
This file provides utility functions for lifting and unlifting equalities.
A type alias for lifting/unlifting functions.
Equations
- liftMetadata = (Lean.Expr → Lean.Level → List Lean.Expr → Lean.MetaM (Lean.Expr × List Lean.Expr))
Instances For
A type alias for finisher functions that construct the final proof of equality after lifting/ unlifting inner expressions.
Equations
Instances For
Transforms an expression using the registered lifting/unlifting functions given in impl_ref. Returns the first successful transformation along with the updated list of proofs.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Rewrites the type of mvarId at the n-th occurrence using heq.
Equations
- mvarId.nthRewrite n heq = do let __do_lift ← mvarId.getType let r ← mvarId.rewrite __do_lift heq false { occs := Lean.Meta.Occurrences.pos [n] } mvarId.replaceTargetEq r.eNew r.eqProof
Instances For
Constructs a proof of equality between the original and transformed expressions using the provided proofs and finisher functions.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Lifts or unlifts an equality expression by transforming both sides using the registered lifting/ unlifting functions. Returns the transformed equality and a proof of equality between the original and transformed expressions.
Equations
- One or more equations did not get rendered due to their size.