Don't rewrite Width to Lg2.

Since we don't rewrite assumptions in the same way, we end up with
silly goals like:

x >= width y => x >= lg2 (y + 1)
This commit is contained in:
Iavor S. Diatchki 2014-12-17 17:39:06 -08:00
parent 5657754442
commit 284e079d59

View File

@ -654,7 +654,12 @@ crySimpExprStep expr =
K (Nat 2) :^^ e -> Just e K (Nat 2) :^^ e -> Just e
_ -> Nothing _ -> Nothing
Width x -> Just (Lg2 (x :+ one)) -- Width x -> Just (Lg2 (x :+ one))
Width x ->
case x of
K a -> Just (K (IN.nWidth a))
K (Nat 2) :^^ e -> Just (one :+ e)
_ -> Nothing
LenFromThen x y w -> LenFromThen x y w ->
case (x,y,w) of case (x,y,w) of