Go to the documentation of this file.
22 #define forall_symbolptr_list(it, list) \
23 for(symbolptr_listt::const_iterator it=(list).begin(); \
24 it!=(list).end(); ++it)
26 #define Forall_symbolptr_list(it, list) \
27 for(symbolptr_listt::iterator it=(list).begin(); \
28 it!=(list).end(); ++it)
32 const std::string &module,
40 symbol_tablet::symbolst::const_iterator it2=
41 symbol_table.
symbols.find(it->second);
43 if(it2==symbol_table.
symbols.end())
51 symbolptr_list.push_back(&s);
54 if(symbolptr_list.empty())
59 else if(symbolptr_list.size()>=2)
61 message.error() <<
"module '" << module <<
"' does not uniquely resolve:\n";
64 message.error() <<
" " << (*it)->name <<
'\n';
72 return *symbolptr_list.front();
77 const std::string &module,
86 for(
const auto &symbol_pair : symbol_table.
symbols)
88 const symbolt &s = symbol_pair.second;
97 symbolptr_list.push_back(&s);
100 if(symbolptr_list.empty())
105 else if(symbolptr_list.size()>=2)
108 std::set<std::string> modules;
111 modules.insert(
id2string((*it)->pretty_name));
113 message.error() <<
"multiple modules found, please select one:\n";
115 for(
const auto &s_it : modules)
116 message.error() <<
" " << s_it <<
'\n';
124 const symbolt &symbol=*symbolptr_list.front();
Class that provides messages with a built-in verbosity 'level'.
const symbol_base_mapt & symbol_base_map
Read-only field, used to look up symbol names given their base names.
typet type
Type of symbol.
Find module symbol using name.
const symbolt & get_module(const symbol_tablet &symbol_table, const std::string &module, message_handlert &message_handler)
irep_idt base_name
Base (non-scoped) name.
irep_idt pretty_name
Language-specific display name.
const symbolt & get_module_by_name(const symbol_tablet &symbol_table, const std::string &module, message_handlert &message_handler)
static const char * message(const static_verifier_resultt::statust &status)
Makes a status message string from a status.
#define forall_symbolptr_list(it, list)
const std::string & id2string(const irep_idt &d)
std::list< const symbolt * > symbolptr_listt
const irep_idt & id() const
const symbolst & symbols
Read-only field, used to look up symbols given their names.
#define forall_symbol_base_map(it, expr, base_name)