Skip to content

Avoid 64-bit platform support requirement for running tests #8213

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

Merged
merged 1 commit into from
Feb 21, 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
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
#include <assert.h>
#include <stdlib.h>

#ifdef _MSC_VER
# define _Static_assert(x, m) static_assert(x, m)
#endif

struct list;

typedef struct list list_nodet;
Expand All @@ -22,11 +15,11 @@ int max_depth = 2;
list_nodet *build_node(int depth)
{
if(max_depth < depth)
return ((list_nodet *)NULL);
return ((list_nodet *)0);
else
{
_Static_assert(sizeof(list_nodet) == 16, "");
list_nodet *result = malloc(16);
__CPROVER_assert(sizeof(list_nodet) == 16, "struct size is 16 bytes");
list_nodet *result = __CPROVER_allocate(16, 0);

if(result)
{
Expand All @@ -53,6 +46,6 @@ int main()
{
i = i + 1;
}
assert(i == 3);
__CPROVER_assert(i == 3, "i should be 3");
return 0;
}
2 changes: 1 addition & 1 deletion regression/cbmc/Pointer_byte_extract8/test.desc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
CORE
main.c
main.i
--no-malloc-may-fail --64 --unwind 4 --unwinding-assertions
^EXIT=0$
^SIGNAL=0$
Expand Down