Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: adaptations for nightly-2024-10-17 #60

Merged
merged 8 commits into from
Oct 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion Qq/ForLean/ReduceEval.lean
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,18 @@ instance [NeZero n] : ReduceEval (Fin n) where
else
throwFailedToEval e

instance {n : Nat} : ReduceEval (BitVec n) where
reduceEval := fun e => do
let e ← whnf e
if e.isAppOfArity ``BitVec.ofFin 2 then
pure ⟨(← reduceEval (e.getArg! 1))⟩
else
throwFailedToEval e

instance : ReduceEval UInt64 where
reduceEval := fun e => do
let e ← whnf e
if e.isAppOfArity ``UInt64.mk 1 then
let _ : ReduceEval (Fin UInt64.size) := inferInstanceAs <| ReduceEval (Fin (_ + 1))
pure ⟨(← reduceEval (e.getArg! 0))⟩
else
throwFailedToEval e
Expand Down
2 changes: 1 addition & 1 deletion lean-toolchain
Original file line number Diff line number Diff line change
@@ -1 +1 @@
leanprover/lean4:v4.13.0-rc3
leanprover/lean4:nightly-2024-10-17
Loading