void abort() { }; /*@ requires ((\old(cond) != 0)) && (cond != 0); ensures ((\old(cond) != 0)) && (1); @*/ void __VERIFIER_assert(int cond) { if(!(cond)) { ERROR: {/*@ assert(0); */;abort();} } } int main() { int x = 40; /*@ loop invariant (((0 <= x) && (x <= 40))); @*/ while (x != 0) { __VERIFIER_assert(x <= 40); x--; __VERIFIER_assert(x >= 0); } __VERIFIER_assert(x == 0); return 0; }