fix: isDeltaCandidate?
It should return `some ...` only if `ConstantInfo` has a value.
This commit is contained in:
parent
10a10b38d8
commit
c17a1c382f
1 changed files with 6 additions and 3 deletions
|
|
@ -938,10 +938,13 @@ private def processAssignment' (mvarApp : Expr) (v : Expr) : MetaM Bool := do
|
||||||
else
|
else
|
||||||
return false
|
return false
|
||||||
|
|
||||||
private def isDeltaCandidate? (t : Expr) : MetaM (Option ConstantInfo) :=
|
private def isDeltaCandidate? (t : Expr) : MetaM (Option ConstantInfo) := do
|
||||||
match t.getAppFn with
|
match t.getAppFn with
|
||||||
| Expr.const c _ _ => getConst? c
|
| Expr.const c _ _ =>
|
||||||
| _ => pure none
|
match (← getConst? c) with
|
||||||
|
| r@(some info) => if info.hasValue then return r else return none
|
||||||
|
| _ => return none
|
||||||
|
| _ => pure none
|
||||||
|
|
||||||
/-- Auxiliary method for isDefEqDelta -/
|
/-- Auxiliary method for isDefEqDelta -/
|
||||||
private def isListLevelDefEq (us vs : List Level) : MetaM LBool :=
|
private def isListLevelDefEq (us vs : List Level) : MetaM LBool :=
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue