@@ -173,6 +173,8 @@ void code_contractst::check_apply_loop_contracts(
173173 initial_invariant_val, invariant};
174174 initial_invariant_value_assignment.add_source_location () =
175175 loop_head_location;
176+
177+ goto_convertt converter (symbol_table, log.get_message_handler ());
176178 converter.goto_convert (
177179 initial_invariant_value_assignment, pre_loop_head_instrs, mode);
178180 }
@@ -293,6 +295,8 @@ void code_contractst::check_apply_loop_contracts(
293295 assertion.add_source_location () = loop_head_location;
294296 assertion.add_source_location ().set_comment (
295297 " Check loop invariant before entry" );
298+
299+ goto_convertt converter (symbol_table, log.get_message_handler ());
296300 converter.goto_convert (assertion, pre_loop_head_instrs, mode);
297301 }
298302
@@ -338,6 +342,8 @@ void code_contractst::check_apply_loop_contracts(
338342 {
339343 code_assumet assumption{invariant};
340344 assumption.add_source_location () = loop_head_location;
345+
346+ goto_convertt converter (symbol_table, log.get_message_handler ());
341347 converter.goto_convert (assumption, pre_loop_head_instrs, mode);
342348 }
343349
@@ -393,6 +399,8 @@ void code_contractst::check_apply_loop_contracts(
393399 code_assignt old_decreases_assignment{
394400 old_decreases_vars[i], decreases_clause_exprs[i]};
395401 old_decreases_assignment.add_source_location () = loop_head_location;
402+
403+ goto_convertt converter (symbol_table, log.get_message_handler ());
396404 converter.goto_convert (
397405 old_decreases_assignment, pre_loop_head_instrs, mode);
398406 }
@@ -441,6 +449,8 @@ void code_contractst::check_apply_loop_contracts(
441449 assertion.add_source_location () = loop_head_location;
442450 assertion.add_source_location ().set_comment (
443451 " Check that loop invariant is preserved" );
452+
453+ goto_convertt converter (symbol_table, log.get_message_handler ());
444454 converter.goto_convert (assertion, pre_loop_end_instrs, mode);
445455 }
446456
@@ -453,6 +463,8 @@ void code_contractst::check_apply_loop_contracts(
453463 code_assignt new_decreases_assignment{
454464 new_decreases_vars[i], decreases_clause_exprs[i]};
455465 new_decreases_assignment.add_source_location () = loop_head_location;
466+
467+ goto_convertt converter (symbol_table, log.get_message_handler ());
456468 converter.goto_convert (
457469 new_decreases_assignment, pre_loop_end_instrs, mode);
458470 }
@@ -465,6 +477,8 @@ void code_contractst::check_apply_loop_contracts(
465477 monotonic_decreasing_assertion.add_source_location () = loop_head_location;
466478 monotonic_decreasing_assertion.add_source_location ().set_comment (
467479 " Check decreases clause on loop iteration" );
480+
481+ goto_convertt converter (symbol_table, log.get_message_handler ());
468482 converter.goto_convert (
469483 monotonic_decreasing_assertion, pre_loop_end_instrs, mode);
470484
@@ -706,6 +720,7 @@ void code_contractst::apply_function_contract(
706720 .append (" in " )
707721 .append (function.c_str ()));
708722 _location.set_property_class (ID_precondition);
723+ goto_convertt converter (symbol_table, log.get_message_handler ());
709724 generate_contract_constraints (
710725 symbol_table,
711726 converter,
@@ -785,6 +800,8 @@ void code_contractst::apply_function_contract(
785800 source_locationt _location = clause.source_location ();
786801 _location.set_comment (" Assume ensures clause" );
787802 _location.set_property_class (ID_assume);
803+
804+ goto_convertt converter (symbol_table, log.get_message_handler ());
788805 generate_contract_constraints (
789806 symbol_table,
790807 converter,
@@ -1355,6 +1372,7 @@ void code_contractst::add_contract_check(
13551372 source_locationt _location = clause.source_location ();
13561373 _location.set_comment (" Assume requires clause" );
13571374 _location.set_property_class (ID_assume);
1375+ goto_convertt converter (symbol_table, log.get_message_handler ());
13581376 generate_contract_constraints (
13591377 symbol_table,
13601378 converter,
@@ -1388,6 +1406,7 @@ void code_contractst::add_contract_check(
13881406 source_locationt _location = clause.source_location ();
13891407 _location.set_comment (" Check ensures clause" );
13901408 _location.set_property_class (ID_postcondition);
1409+ goto_convertt converter (symbol_table, log.get_message_handler ());
13911410 generate_contract_constraints (
13921411 symbol_table,
13931412 converter,
0 commit comments