-
Notifications
You must be signed in to change notification settings - Fork 123
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix off-by-one error in What4 implementation of (@)
In the case where the index is a symbolic `Integer` and the sequence is of length `n`, the What4 backend mistakenly chose `n` to be the largest possible index. This corrects it to instead be `n - 1`. Fixes #1359.
- Loading branch information
1 parent
9e59289
commit c37a71b
Showing
4 changed files
with
20 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
:set prover=sbv-z3 | ||
:safe \a -> sortBy (\c1 c2 -> c2 != ' ') (split`{8} a) | ||
:safe \(a : [64]) (i : Integer) -> (split`{8} a)@(max 0 (min i 7)) | ||
|
||
:set prover=w4-z3 | ||
:safe \a -> sortBy (\c1 c2 -> c2 != ' ') (split`{8} a) | ||
:safe \(a : [64]) (i : Integer) -> (split`{8} a)@(max 0 (min i 7)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Loading module Cryptol | ||
Safe | ||
Safe | ||
Safe | ||
Safe |