cprover
struct_union_typet Class Reference

Base type of C structs and unions, and C++ classes. More...

#include <std_types.h>

Inheritance diagram for struct_union_typet:
[legend]
Collaboration diagram for struct_union_typet:
[legend]

Classes

class  componentt
 

Public Types

typedef std::vector< componenttcomponentst
 
- Public Types inherited from typet
typedef std::vector< typetsubtypest
 
- Public Types inherited from irept
typedef std::vector< ireptsubt
 
typedef std::map< irep_namet, ireptnamed_subt
 

Public Member Functions

 struct_union_typet (const irep_idt &_id)
 
const componentstcomponents () const
 
componentstcomponents ()
 
bool has_component (const irep_idt &component_name) const
 
const componenttget_component (const irep_idt &component_name) const
 
std::size_t component_number (const irep_idt &component_name) const
 
typet component_type (const irep_idt &component_name) const
 
irep_idt get_tag () const
 
void set_tag (const irep_idt &tag)
 
- Public Member Functions inherited from typet
 typet ()
 
 typet (const irep_idt &_id)
 
 typet (const irep_idt &_id, const typet &_subtype)
 
const typetsubtype () const
 
typetsubtype ()
 
subtypestsubtypes ()
 
const subtypestsubtypes () const
 
bool has_subtypes () const
 
bool has_subtype () const
 
void remove_subtype ()
 
void move_to_subtypes (typet &type)
 
void copy_to_subtypes (const typet &type)
 
const source_locationtsource_location () const
 
source_locationtadd_source_location ()
 
typetadd_type (const irep_namet &name)
 
const typetfind_type (const irep_namet &name) const
 
- Public Member Functions inherited from irept
bool is_nil () const
 
bool is_not_nil () const
 
 irept (const irep_idt &_id)
 
 irept ()
 
 irept (const irept &irep)
 
 irept (irept &&irep)
 
ireptoperator= (const irept &irep)
 
ireptoperator= (irept &&irep)
 
 ~irept ()
 
const irep_idtid () const
 
const std::string & id_string () const
 
void id (const irep_idt &_data)
 
const ireptfind (const irep_namet &name) const
 
ireptadd (const irep_namet &name)
 
ireptadd (const irep_namet &name, const irept &irep)
 
const std::string & get_string (const irep_namet &name) const
 
const irep_idtget (const irep_namet &name) const
 
bool get_bool (const irep_namet &name) const
 
signed int get_int (const irep_namet &name) const
 
unsigned int get_unsigned_int (const irep_namet &name) const
 
std::size_t get_size_t (const irep_namet &name) const
 
long long get_long_long (const irep_namet &name) const
 
void set (const irep_namet &name, const irep_idt &value)
 
void set (const irep_namet &name, const irept &irep)
 
void set (const irep_namet &name, const long long value)
 
void remove (const irep_namet &name)
 
void move_to_sub (irept &irep)
 
void move_to_named_sub (const irep_namet &name, irept &irep)
 
bool operator== (const irept &other) const
 
bool operator!= (const irept &other) const
 
void swap (irept &irep)
 
bool operator< (const irept &other) const
 defines ordering on the internal representation More...
 
bool ordering (const irept &other) const
 defines ordering on the internal representation More...
 
int compare (const irept &i) const
 defines ordering on the internal representation More...
 
void clear ()
 
void make_nil ()
 
subtget_sub ()
 
const subtget_sub () const
 
named_subtget_named_sub ()
 
const named_subtget_named_sub () const
 
named_subtget_comments ()
 
const named_subtget_comments () const
 
std::size_t hash () const
 
std::size_t full_hash () const
 
bool full_eq (const irept &other) const
 
std::string pretty (unsigned indent=0, unsigned max_indent=0) const
 
const dtread () const
 
dtwrite ()
 

Additional Inherited Members

- Protected Member Functions inherited from irept
void detach ()
 
- Static Protected Member Functions inherited from irept
static bool is_comment (const irep_namet &name)
 
static void remove_ref (dt *old_data)
 
static void nonrecursive_destructor (dt *old_data)
 Does the same as remove_ref, but using an explicit stack instead of recursion. More...
 
- Protected Attributes inherited from irept
dtdata
 
- Static Protected Attributes inherited from irept
static dt empty_d
 

Detailed Description

Base type of C structs and unions, and C++ classes.

Definition at line 159 of file std_types.h.

Member Typedef Documentation

§ componentst

Definition at line 240 of file std_types.h.

Constructor & Destructor Documentation

§ struct_union_typet()

struct_union_typet::struct_union_typet ( const irep_idt _id)
inlineexplicit

Definition at line 162 of file std_types.h.

Member Function Documentation

§ component_number()

std::size_t struct_union_typet::component_number ( const irep_idt component_name) const

§ component_type()

typet struct_union_typet::component_type ( const irep_idt component_name) const

Definition at line 68 of file std_types.cpp.

References irept::is_not_nil(), and exprt::type().

Referenced by value_sett::make_member(), and fence_insertert::type_component().

§ components() [1/2]

const componentst& struct_union_typet::components ( ) const
inline

Definition at line 242 of file std_types.h.

References irept::find(), and irept::get_sub().

Referenced by cpp_typecheckt::add_anonymous_members_to_scope(), java_bytecode_convert_classt::add_array_types(), cpp_typecheckt::add_base_components(), goto_program2codet::add_local_types(), add_padding(), java_bytecode_convert_classt::add_string_type(), java_bytecode_vtable_factoryt::add_vtable_entry(), add_vtable_pointer_member(), linkingt::adjust_object_type_rec(), alignment(), value_sett::assign(), value_set_fit::assign(), value_set_fivrnst::assign(), value_set_fivrt::assign(), path_symext::assign_rec(), base_type_eqt::base_type_eq_rec(), base_type_rec(), smt1_convt::binary2struct(), smt1_convt::binary2union(), simplify_exprt::bits2expr(), string_abstractiont::build_abstraction_type_rec(), endianness_mapt::build_big_endian(), build_class_identifier(), boolbvt::build_offset_map(), boolbvt::bv_get_rec(), c_sizeoft::c_offsetof(), check_renaming(), value_set_analysis_fit::check_type(), value_set_analysis_fivrt::check_type(), value_set_analysis_fivrnst::check_type(), cpp_typecheckt::clean_up(), dump_ct::cleanup_expr(), cpp_declarator_convertert::convert(), java_bytecode_convert_classt::convert(), graphml_witnesst::convert_assign_rec(), dump_ct::convert_compound(), dplib_convt::convert_dplib_expr(), dplib_convt::convert_dplib_type(), expr2ct::convert_member(), boolbvt::convert_member(), expr2ct::convert_rec(), expr2javat::convert_struct(), expr2cppt::convert_struct(), smt1_convt::convert_struct(), boolbvt::convert_struct(), smt2_convt::convert_struct(), expr2ct::convert_struct(), cvc_convt::convert_struct_expr(), expr2ct::convert_struct_type(), cvc_convt::convert_type(), boolbvt::convert_update_rec(), boolbvt::convert_with_struct(), cpp_typecheckt::cpp_constructor(), cpp_typecheckt::cpp_destructor(), cpp_typecheckt::cpp_is_pod(), cpp_typecheckt::default_cpctor(), c_typecheck_baset::designator_enter(), linkingt::detailed_conflict_report_rec(), c_typecheck_baset::do_designated_initializer(), c_typecheck_baset::do_initializer_list(), cpp_typecheckt::do_virtual_table(), cpp_typecheckt::dtor(), linkingt::duplicate_code_symbol(), interpretert::evaluate_address(), path_symex_statet::expand_structs_and_arrays(), cpp_typecheckt::find_assignop(), cpp_typecheckt::find_cpctor(), find_superclass_with_type(), find_symbols(), smt1_convt::find_symbols_rec(), smt2_convt::find_symbols_rec(), smt2_convt::flatten2bv(), flatten_byte_extract(), cpp_typecheckt::full_member_initialization(), java_object_factoryt::gen_nondet_array_init(), java_object_factoryt::gen_nondet_struct_init(), refined_string_typet::get_char_type(), java_bytecode_parsert::get_class_refs_rec(), get_component_rec(), refined_string_typet::get_content_type(), value_set_analysis_fit::get_entries_rec(), value_set_analysis_fivrt::get_entries_rec(), value_set_analysis_fivrnst::get_entries_rec(), boolbv_widtht::get_entry(), invariant_propagationt::get_objects_rec(), goto_symex_statet::get_original_name(), interpretert::get_size(), value_sett::get_value_set_rec(), java_bytecode_vtable_factoryt::has_component(), has_component_rec(), have_to_remove_complex(), have_to_remove_vector(), rename_symbolt::have_to_rename(), replace_symbolt::have_to_replace(), c_typecheck_baset::increment_designator(), goto_symext::initialize_auto_object(), cpp_typecheckt::instantiate_template(), jsil_union_typet::intersect_with(), c_typecheck_baset::is_complete_type(), struct_typet::is_prefix_of(), jsil_union_typet::is_subtype(), java_root_class(), jsil_incompatible_types(), jsil_union_typet::jsil_union_typet(), json(), cpp_typecheck_resolvet::make_constructors(), c_typecheck_baset::make_designator(), string_abstractiont::make_val_or_dummy_rec(), member_offset(), member_offset_expr(), member_offset_iterator::operator++(), cpp_typecheckt::operator_is_overloaded(), smt2_convt::parse_struct(), smt2_convt::parse_union(), pointer_offset_bits(), print_struct_alignment_problems(), cpp_typecheckt::reference_binding(), refined_string_typet::refined_string_typet(), remove_complex(), goto_program2codet::remove_const(), remove_vector(), rename_symbolt::rename(), goto_symex_statet::rename(), replace_symbolt::replace(), set_class_identifier(), simplify_exprt::simplify_byte_extract(), size_of_expr(), c_sizeoft::sizeof_rec(), invariant_sett::strengthen_rec(), string_abstractiont::string_abstractiont(), jsil_union_typet::to_type(), type2name(), boolbvt::type_conversion(), linkingt::type_to_string_verbose(), cpp_typecheckt::typecheck_compound_bases(), c_typecheck_baset::typecheck_compound_body(), java_bytecode_typecheckt::typecheck_expr_member(), c_typecheck_baset::typecheck_expr_typecast(), cpp_typecheckt::typecheck_side_effect_function_call(), smt2_convt::unflatten(), jsil_union_typet::union_with(), unpack_rec(), cpp_typecheckt::user_defined_conversion_sequence(), string_abstractiont::value_assignments(), xml(), and zero_initializert::zero_initializer_rec().

§ components() [2/2]

componentst& struct_union_typet::components ( )
inline

Definition at line 247 of file std_types.h.

References irept::add(), and irept::get_sub().

§ get_component()

§ get_tag()

§ has_component()

bool struct_union_typet::has_component ( const irep_idt component_name) const
inline

§ set_tag()


The documentation for this class was generated from the following files: