The elaborator is prone to duplicate terms, including recursive calls, even if the user only wrote a single one. This duplication is wasteful if we run the tactics on duplicated calls, and confusing in the output of GuessLex. So prune the list of recursive calls, and remove those where another call exists that has the same goal and context that is no more specific.
13 lines
576 B
Text
13 lines
576 B
Text
Tactic is run (ideally only once)
|
|
Tactic is run (ideally only twice)
|
|
Tactic is run (ideally only twice)
|
|
Tactic is run (ideally only once, in most general context)
|
|
n : Nat
|
|
⊢ (invImage (fun a => sizeOf a) instWellFoundedRelation).1 n (Nat.succ n)
|
|
Tactic is run (ideally only twice, in most general context)
|
|
Tactic is run (ideally only twice, in most general context)
|
|
n : Nat
|
|
⊢ sizeOf n < sizeOf (Nat.succ n)
|
|
n m : Nat
|
|
⊢ (invImage (fun a => PSigma.casesOn a fun x1 snd => sizeOf x1) instWellFoundedRelation).1 { fst := n, snd := m + 1 }
|
|
{ fst := Nat.succ n, snd := m }
|