@@ -35,15 +35,15 @@ def setFailure (goal : Goal) : M Unit := do
3535 modify fun s => { s with failure? := some goal }
3636
3737@[inline] def stepGuard (x : Goal → M Bool) (goal : Goal) : M Bool := do
38- try
39- x goal
40- catch ex =>
41- if ex.isMaxHeartbeat || ex.isMaxRecDepth then
42- reportIssue! ex.toMessageData
43- setFailure goal
44- return true
45- else
46- throw ex
38+ tryCatchRuntimeEx
39+ ( x goal)
40+ fun ex => do
41+ if ex.isMaxHeartbeat || ex.isMaxRecDepth then
42+ reportIssue! ex.toMessageData
43+ setFailure goal
44+ return true
45+ else
46+ throw ex
4747
4848def applyTac (x : GrindTactic) (goal : Goal) : M Bool := do
4949 let go (goal : Goal) : M Bool := do
@@ -52,18 +52,18 @@ def applyTac (x : GrindTactic) (goal : Goal) : M Bool := do
5252 return true
5353 stepGuard go goal
5454
55- def tryAssertNext : Goal → M Bool := applyTac assertNext
55+ def tryAssertAll : Goal → M Bool := applyTac assertAll
5656
57- def tryEmatch : Goal → M Bool := applyTac ematchAndAssert
58-
59- def trySplit : Goal → M Bool := applyTac splitNext
57+ def tryEmatch : Goal → M Bool := applyTac ematch
6058
6159def tryArith : Goal → M Bool := applyTac Arith.check
6260
6361def tryLookahead : Goal → M Bool := applyTac lookahead
6462
6563def tryMBTC : Goal → M Bool := applyTac Arith.Cutsat.mbtcTac
6664
65+ def trySplit : Goal → M Bool := applyTac splitNext
66+
6767partial def main (fallback : Fallback) : M Unit := do
6868 repeat do
6969 if (← get).failure?.isSome then
@@ -72,7 +72,7 @@ partial def main (fallback : Fallback) : M Unit := do
7272 return ()
7373 if goal.inconsistent then
7474 continue
75- if (← tryAssertNext goal) then
75+ if (← tryAssertAll goal) then
7676 continue
7777 if (← tryArith goal) then
7878 continue
0 commit comments