File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -37,10 +37,11 @@ private def resumePostponed (savedContext : SavedContext) (stx : Syntax) (mvarId
3737 let mvarDecl ← getMVarDecl mvarId
3838 let expectedType ← instantiateMVars mvarDecl.type
3939 withInfoHole mvarId do
40- let result ← resumeElabTerm stx expectedType (!postponeOnError)
41- /- We must ensure `result` has the expected type because it is the one expected by the method that postponed stx.
42- That is, the method does not have an opportunity to check whether `result` has the expected type or not. -/
43- let result ← withRef stx <| ensureHasType expectedType result
40+ let result ← withTermInfoContext' .anonymous stx do
41+ let result ← resumeElabTerm stx expectedType (!postponeOnError)
42+ /- We must ensure `result` has the expected type because it is the one expected by the method that postponed stx.
43+ That is, the method does not have an opportunity to check whether `result` has the expected type or not. -/
44+ withRef stx <| ensureHasType expectedType result
4445 /- We must perform `occursCheck` here since `result` may contain `mvarId` when it has synthetic `sorry`s. -/
4546 if (← occursCheck mvarId result) then
4647 mvarId.assign result
You can’t perform that action at this time.
0 commit comments