34 std::set<irep_idt> added_functions;
38 std::unordered_set<irep_idt> called_functions =
43 std::set<irep_idt> missing_functions;
45 for(
const auto &
id : called_functions)
47 goto_functionst::function_mapt::const_iterator f_it =
52 f_it->second.body_available())
56 else if(added_functions.find(
id) != added_functions.end())
61 missing_functions.insert(
id);
65 if(missing_functions.empty())
68 library(missing_functions, goto_model.
symbol_table, message_handler);
71 for(
const auto &
id : missing_functions)
84 added_functions.insert(
id);
function_mapt function_map
symbol_tablet symbol_table
Symbol table.
goto_functionst goto_functions
GOTO functions.
const symbolst & symbols
Read-only field, used to look up symbols given their names.
std::unordered_set< irep_idt > compute_called_functions(const goto_functionst &goto_functions)
computes the functions that are (potentially) called
void goto_convert(const codet &code, symbol_table_baset &symbol_table, goto_programt &dest, message_handlert &message_handler, const irep_idt &mode)
Goto Programs with Functions.
void link_to_library(goto_modelt &goto_model, message_handlert &message_handler, const std::function< void(const std::set< irep_idt > &, symbol_tablet &, message_handlert &)> &library)
Complete missing function definitions using the library.