29 if(src.
id() == ID_symbol && current)
31 else if(src.
id() == ID_next_symbol && next)
32 dest.insert(src.
get(ID_identifier));
46 if(src.
id() == ID_symbol && current)
48 else if(src.
id() == ID_next_symbol && next)
49 return symbols.count(src.
get(ID_identifier))!=0;
69 std::set<exprt> &dest)
71 if(src.
id()==ID_symbol || src.
id()==ID_next_symbol)
82 std::set<symbol_exprt> &dest)
84 if(src.
id()==ID_symbol)
104 if(src.
id() == ID_symbol)
106 else if(src.
id() == ID_next_symbol)
107 dest.insert(src.
get(ID_identifier));
110 const irept &c_sizeof_type=src.
find(ID_C_c_sizeof_type);
113 find_symbols(kind, static_cast<const typet &>(c_sizeof_type), dest);
115 const irept &va_arg_type=src.
find(ID_C_va_arg_type);
118 find_symbols(kind, static_cast<const typet &>(va_arg_type), dest);
124 src.
id()!=ID_pointer)
132 const irep_idt &typedef_name=src.
get(ID_C_typedef);
133 if(!typedef_name.
empty())
134 dest.insert(typedef_name);
137 if(src.
id()==ID_struct ||
144 for(struct_union_typet::componentst::const_iterator
145 it=components.begin();
146 it!=components.end();
150 else if(src.
id()==ID_code)
156 for(code_typet::parameterst::const_iterator
157 it=parameters.begin();
158 it!=parameters.end();
168 else if(src.
id()==ID_symbol)
170 else if(src.
id()==ID_array)
175 else if(src.
id()==ID_c_enum_tag)
179 else if(src.
id()==ID_struct_tag)
183 else if(src.
id()==ID_union_tag)
The type of an expression.
#define forall_subtypes(it, type)
const code_typet & to_code_type(const typet &type)
Cast a generic typet to a code_typet.
std::vector< componentt > componentst
const symbol_typet & to_symbol_type(const typet &type)
Cast a generic typet to a symbol_typet.
std::vector< parametert > parameterst
const componentst & components() const
const irep_idt & id() const
const union_tag_typet & to_union_tag_type(const typet &type)
Cast a generic typet to a union_tag_typet.
API to expression classes.
const irep_idt & get(const irep_namet &name) const
const struct_tag_typet & to_struct_tag_type(const typet &type)
Cast a generic typet to a union_tag_typet.
Base class for tree-like data structures with sharing.
#define forall_operands(it, expr)
const symbol_exprt & to_symbol_expr(const exprt &expr)
Cast a generic exprt to a symbol_exprt.
bool has_symbol(const exprt &src, const find_symbols_sett &symbols, bool current, bool next)
const c_enum_tag_typet & to_c_enum_tag_type(const typet &type)
Cast a generic typet to a c_enum_tag_typet.
void find_non_pointer_type_symbols(const exprt &src, find_symbols_sett &dest)
Base type of C structs and unions, and C++ classes.
const array_typet & to_array_type(const typet &type)
Cast a generic typet to an array_typet.
Base class for all expressions.
const parameterst & parameters() const
const struct_union_typet & to_struct_union_type(const typet &type)
Cast a generic typet to a struct_union_typet.
void find_type_and_expr_symbols(const exprt &src, find_symbols_sett &dest)
std::unordered_set< irep_idt > find_symbols_sett
const typet & subtype() const
void find_type_symbols(const exprt &src, find_symbols_sett &dest)
const irept & find(const irep_namet &name) const
void find_symbols(const exprt &src, find_symbols_sett &dest)
const typet & return_type() const