fix: literals are bottom-up safe

This commit is contained in:
Daniel Selsam 2021-07-29 09:17:34 -07:00 committed by Sebastian Ullrich
parent a96a043618
commit 2f9963f092

View file

@ -189,7 +189,7 @@ partial def okBottomUp? (e : Expr) (mvar? : Option Expr := none) (fuel : Nat :=
match fuel with
| 0 => BottomUpKind.unsafe
| fuel + 1 =>
if e.isFVar then return BottomUpKind.safe
if e.isFVar || e.isNatLit || e.isStringLit then return BottomUpKind.safe
if getPPAnalyzeTrustOfNat (← getOptions) && e.isAppOfArity `OfNat.ofNat 3 then return BottomUpKind.safe
if e.isApp || e.isConst then
match e.getAppFn with