lean4-htt/tests/pkg/cbv_attr/CbvAttr/PublicFunctionLocalTheorem.lean
Wojciech Różowski 7d32030729
feat: add cbv_eval attribute (#12296)
This PR adds `cbv_eval` attribute that allows to evaluate functions in
`cbv` tactic using pre-registered theorems.
2026-02-10 15:41:42 +00:00

12 lines
231 B
Text

module
set_option cbv.warning false
@[cbv_opaque] public def f2 (x : Nat) :=
x + 1
private axiom myAx : f2 x = x + 1
@[local cbv_eval] public theorem f2_spec : f2 x = x + 1 := myAx
example : f2 1 = 2 := by conv => lhs; cbv