fix: nontermination
This commit is contained in:
parent
b7c82d40a2
commit
f73615c3d2
3 changed files with 13 additions and 1 deletions
|
|
@ -294,7 +294,11 @@ mutual
|
|||
loop ()
|
||||
else
|
||||
reportStuckSyntheticMVars
|
||||
loop ()
|
||||
/- Disable `autoBoundImplicit` to avoid nontermination.
|
||||
The postponed terms have a fixed `localContext`, i.e. the context of the metavariable representing the "hole".
|
||||
`throwAutoBoundImplicit` exception will have not effect. -/
|
||||
withReader (fun ctx => { ctx with autoBoundImplicit := false }) do
|
||||
loop ()
|
||||
end
|
||||
|
||||
def synthesizeSyntheticMVarsNoPostponing : TermElabM Unit :=
|
||||
|
|
|
|||
7
tests/lean/autoBoundPostponeLoop.lean
Normal file
7
tests/lean/autoBoundPostponeLoop.lean
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
theorem ex
|
||||
(h₁ : α = β)
|
||||
(as : List α)
|
||||
(bs : List β)
|
||||
(h₂ : (h ▸ as) = bs)
|
||||
: True :=
|
||||
True.intro
|
||||
1
tests/lean/autoBoundPostponeLoop.lean.expected.out
Normal file
1
tests/lean/autoBoundPostponeLoop.lean.expected.out
Normal file
|
|
@ -0,0 +1 @@
|
|||
autoBoundPostponeLoop.lean:5:12-5:13: error: unknown identifier 'h'
|
||||
Loading…
Add table
Reference in a new issue