UTBotCpp
UTBotCpp copied to clipboard
To catch C/C++ signed/unsigned overflow
Great Improvement has been made for UTBot 167, more robust and stable. but I am expecting UTBOT to catch C/C++ signed/unsigned overflow directly.
int absolute(int a)
{
if (a < 0){
return -a;
}
else {
return a;
}
}
typedef unsigned int uint32_t;
uint32_t change_val()
{
uint32_t val=255*1024*1024;
uint32_t new_val;
new_val = (((uint32_t)(val))*1024*1024);
return new_val;
}
There are overflow in above 2 functions, but UTbot didn't report issue. Can UTBot report issue (or at least warn users) if there is overflow issues?
@sava-cska, please investigate test generation then the option is on.