forked from diffblue/cbmc
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Explicit type cast to avoid signed/unsigned warning
- Loading branch information
1 parent
8187bdd
commit 96a7014
Showing
2 changed files
with
6 additions
and
2 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,7 +15,8 @@ Author: Daniel Kroening, [email protected] | |
#include <util/irep.h> | ||
|
||
#define MAX_NONDET_ARRAY_LENGTH_DEFAULT 5 | ||
#define MAX_NONDET_STRING_LENGTH std::numeric_limits<std::int32_t>::max() | ||
#define MAX_NONDET_STRING_LENGTH \ | ||
static_cast<std::size_t>(std::numeric_limits<std::int32_t>::max()) | ||
#define MAX_NONDET_TREE_DEPTH 5 | ||
#define MAX_NONNULL_TREE_DEPTH 0 | ||
|
||
|
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 |
---|---|---|
|
@@ -14,6 +14,7 @@ Author: Daniel Kroening, [email protected] | |
#include <unistd.h> | ||
#endif | ||
|
||
#include <limits> | ||
#include <stack> | ||
|
||
#include <util/invariant.h> | ||
|
@@ -28,7 +29,9 @@ Author: Daniel Kroening, [email protected] | |
|
||
void convert(const bvt &bv, Minisat::vec<Minisat::Lit> &dest) | ||
{ | ||
dest.capacity(bv.size()); | ||
PRECONDITION( | ||
bv.size() <= static_cast<std::size_t>(std::numeric_limits<int>::max())); | ||
dest.capacity(static_cast<int>(bv.size())); | ||
|
||
forall_literals(it, bv) | ||
if(!it->is_false()) | ||
|