This PR modifies the pretty printing of anonymous metavariables to use the index rather than the internal name. This leads to smaller numerical suffixes in `?m.123` since the indices are numbered within a given metavariable context rather than across an entire file, hence each command gets its own numbering. This does not yet affect pretty printing of universe level metavariables. For debugging purposes, metavariables that are not defined now pretty print as `?_mvar.123` rather than cause pretty printing to fail.
24 lines
370 B
Text
24 lines
370 B
Text
/-!
|
|
# Tests for the `have` tactic.
|
|
-/
|
|
|
|
/-!
|
|
If the body of a `have` fails to elaborate, the tactic completes with a `sorry` for the proof.
|
|
-/
|
|
/--
|
|
error: Type mismatch
|
|
False.elim
|
|
has type
|
|
False → ?m.2
|
|
but is expected to have type
|
|
True
|
|
---
|
|
trace: h : True
|
|
⊢ True
|
|
-/
|
|
#guard_msgs in
|
|
example : True := by
|
|
have h : True :=
|
|
False.elim
|
|
trace_state
|
|
assumption
|