CBMC
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
resolve_inherited_component.h
Go to the documentation of this file.
1/*******************************************************************\
2
3Module: GOTO Program Utilities
4
5Author: Diffblue Ltd.
6
7\*******************************************************************/
8
12
13#ifndef CPROVER_GOTO_PROGRAMS_RESOLVE_INHERITED_COMPONENT_H
14#define CPROVER_GOTO_PROGRAMS_RESOLVE_INHERITED_COMPONENT_H
15
16#include <util/irep.h>
17
18#include <functional>
19#include <optional>
20
21class symbolt;
23
25{
26public:
28
49
50 std::optional<inherited_componentt> operator()(
51 const irep_idt &class_id,
52 const irep_idt &component_name,
54 std::function<bool(const symbolt &)> user_filter = [](const symbolt &) {
55 return true;
56 });
57
59 const irep_idt &class_name, const irep_idt &component_name);
60
61private:
63};
64
65std::optional<resolve_inherited_componentt::inherited_componentt>
68 const irep_idt &classname,
69 const symbol_table_baset &symbol_table);
70
71#endif // CPROVER_GOTO_PROGRAMS_RESOLVE_INHERITED_COMPONENT_H
ait supplies three of the four components needed: an abstract interpreter (in this case handling func...
Definition ai.h:562
dstringt has one field, an unsigned integer no which is an index into a static table of strings.
Definition dstring.h:38
inherited_componentt(const irep_idt &class_id, const irep_idt &component_id)
irep_idt get_full_component_identifier() const
Get the full name of this function.
std::optional< inherited_componentt > operator()(const irep_idt &class_id, const irep_idt &component_name, bool include_interfaces, std::function< bool(const symbolt &)> user_filter=[](const symbolt &) { return true;})
Given a class and a component, identify the concrete field or method it is resolved to.
static irep_idt build_full_component_identifier(const irep_idt &class_name, const irep_idt &component_name)
Build a component name as found in a GOTO symbol table equivalent to the name of a concrete component...
const symbol_table_baset & symbol_table
The symbol table base class interface.
Symbol table entry.
Definition symbol.h:28
std::optional< resolve_inherited_componentt::inherited_componentt > get_inherited_method_implementation(const irep_idt &call_basename, const irep_idt &classname, const symbol_table_baset &symbol_table)
Given a class and a component, identify the concrete method it is resolved to.