Open sim642 opened 2 hours ago
A simple do-while loop like
do
while
do { i++; } while (i < 10);
is converted to the following (according to Goblint's justcil):
justcil
{ #line 6 while (1) { while_continue: /* CIL Label */ ; #line 7 i ++; #line 6 if (! (i < 10)) { #line 6 goto while_break; } } while_break: /* CIL Label */ ; }
The location of while_continue label there is wrong! According to cppreference, it should be like:
while_continue
do { // ... continue; // acts as goto contin; // ... contin:; } while (/* ... */);
Wow! Amazing this was only discovered after almost 2 decades of CIL!
A simple
do
-while
loop likeis converted to the following (according to Goblint's
justcil
):The location of
while_continue
label there is wrong! According to cppreference, it should be like: