We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f1d4b2f commit a9a6986Copy full SHA for a9a6986
src/goto-instrument/contracts/contracts.cpp
@@ -236,10 +236,14 @@ void code_contractst::check_apply_loop_contracts(
236
new_decreases_vars.push_back(new_decreases_var);
237
}
238
239
- // non-deterministically skip the loop if it is a do-while loop.
240
// TODO: Fix loop contract issues for do/while loops.
241
if(!loop_head->is_goto())
242
{
+ log.error() << "Loop contracts are currently unsupported on do/while loops."
243
+ << loop_head->source_location() << messaget::eom;
244
+ throw 0;
245
+
246
+ // non-deterministically skip the loop if it is a do-while loop.
247
generated_code.add(goto_programt::make_goto(
248
loop_end,
249
side_effect_expr_nondett(bool_typet(), loop_head->source_location())));
0 commit comments