-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Flag for non-linear integer arithmetic (#709)
* disable nlir * disable NLIR * cure dyslexia * test * Update src/main/scala/viper/gobra/frontend/Config.scala Co-authored-by: João Pereira <joaopereira.19@gmail.com> * Update src/main/scala/viper/gobra/frontend/Config.scala Co-authored-by: João Pereira <joaopereira.19@gmail.com> * z3 api and tests --------- Co-authored-by: João Pereira <joaopereira.19@gmail.com>
- Loading branch information
Showing
4 changed files
with
49 additions
and
0 deletions.
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,13 @@ | ||
// Any copyright is dedicated to the Public Domain. | ||
// http://creativecommons.org/publicdomain/zero/1.0/ | ||
|
||
// ##(--disableNL) | ||
package pkg | ||
|
||
requires 0 <= x && x <= 10 | ||
requires 0 <= y && y <= 10 | ||
//:: ExpectedOutput(postcondition_error:assertion_error) | ||
ensures 0 <= res && res <= 100 | ||
func f(x, y int) (res int) { | ||
return x * y | ||
} |
11 changes: 11 additions & 0 deletions
11
src/test/resources/regressions/examples/disableNL_success.gobra
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,11 @@ | ||
// Any copyright is dedicated to the Public Domain. | ||
// http://creativecommons.org/publicdomain/zero/1.0/ | ||
|
||
package pkg | ||
|
||
requires 0 <= x && x <= 10 | ||
requires 0 <= y && y <= 10 | ||
ensures 0 <= res && res <= 100 | ||
func f(x, y int) (res int) { | ||
return x * y | ||
} |