22 const std::map<
loop_idt, std::set<exprt>> &assigns_map,
44 std::map<std::string, json_arrayt> function_map;
62 function_map.find(
id2string(head->source_location().get_function()));
65 std::string function_name =
66 id2string(head->source_location().get_function());
118 for(
const auto &loop_contracts : function_map)
ait supplies three of the four components needed: an abstract interpreter (in this case handling func...
function_mapt function_map
symbol_tablet symbol_table
Symbol table.
goto_functionst goto_functions
GOTO functions.
Provides methods for streaming JSON objects.
void push_back(const std::string &key, const jsont &json)
Push back a JSON element into the current object stream.
A namespacet is essentially one or two symbol tables bound together, to allow for symbol lookups in t...
void dump_loop_contracts(goto_modelt &goto_model, const std::map< loop_idt, exprt > &invariant_map, const std::map< loop_idt, std::set< exprt > > &assigns_map, const std::string &json_output_str, std::ostream &out)
Dump Loop Contracts as JSON.
std::string expr2c(const exprt &expr, const namespacet &ns, const expr2c_configurationt &configuration)
const std::string & id2string(const irep_idt &d)
exprt simplify_expr(exprt src, const namespacet &ns)
#define INVARIANT(CONDITION, REASON)
This macro uses the wrapper function 'invariant_violated_string'.
static expr2c_configurationt clean_configuration
This prints compilable C that loses some of the internal details of the GOTO program.
Loop id used to identify loops.
goto_programt::targett get_loop_head(const unsigned int target_loop_number, goto_functiont &function)
Find and return the first instruction of the natural loop with loop_number in function.