@@ -37,16 +37,14 @@ private def resumePostponed (savedContext : SavedContext) (stx : Syntax) (mvarId
3737 let mvarDecl ← getMVarDecl mvarId
3838 let expectedType ← instantiateMVars mvarDecl.type
3939 let ret ← withInfoHole mvarId do
40- logInfo m!"resumeElabTerm..."
4140 let result ← resumeElabTerm stx expectedType (!postponeOnError)
4241 /- We must ensure `result` has the expected type because it is the one expected by the method that postponed stx.
4342 That is, the method does not have an opportunity to check whether `result` has the expected type or not. -/
44- logInfo m!"ensureHasType..."
4543 let result ← do
4644 if (← getInfoState).enabled then
4745 let savedInfoTrees ← getResetInfoTrees
4846 -- withRef stx <| ensureHasType expectedType result
49- Prod.fst <$> MonadFinally.tryFinally' (withRef stx <| ensureHasType expectedType result) fun a? => do
47+ Prod.fst <$> MonadFinally.tryFinally' (withRef stx <| ensureHasType expectedType result) fun _ => do
5048 modifyInfoState fun state =>
5149 if savedInfoTrees.size > 0 then
5250 let mod (t : InfoTree) : InfoTree :=
@@ -58,9 +56,6 @@ private def resumePostponed (savedContext : SavedContext) (stx : Syntax) (mvarId
5856 { state with trees := savedInfoTrees }
5957 else
6058 withRef stx <| ensureHasType expectedType result
61- let trees ← getInfoTrees
62- let strs ← trees.toArray.mapM (·.format')
63- logInfo m!"withInfoHole inner {strs}"
6459 /- We must perform `occursCheck` here since `result` may contain `mvarId` when it has synthetic `sorry`s. -/
6560 if (← occursCheck mvarId result) then
6661 mvarId.assign result
0 commit comments