1 parent ca8d245 commit c711b53Copy full SHA for c711b53
1 file changed
Inhabit/Sequents.lean
@@ -17,8 +17,8 @@ partial def seqsolve (goal : MVarId) : TacticM Bool :=
17
let _ ← seqsolve newGoal
18
return true
19
20
- matchConstInduct goalType.getAppFn
21
- (fun _ => throwTacticEx `seqsolve goal "target is not an inductive datatype")
+ return ← matchConstInduct goalType.getAppFn
+ (fun _ => return false)
22
fun ival us => do
23
for ctor in ival.ctors do
24
try
@@ -27,10 +27,10 @@ partial def seqsolve (goal : MVarId) : TacticM Bool :=
27
newGoals.forM $ fun newGoal => do
28
if not $ ← seqsolve newGoal then
29
failure
30
+ return true
31
catch _ =>
32
pure ()
-
33
- return false
+ return false
34
35
elab "seqsolve" : tactic =>
36
withMainContext do
0 commit comments