26 for(
const auto &sub_irep : irep.
get_sub())
28 xmlt &x_sub=
xml.new_element(
"sub");
36 xmlt &x_nsub =
xml.new_element(
"named_sub");
38 convert(irep_entry.second, x_nsub);
46 xmlt &x_com =
xml.new_element(
"comment");
48 convert(irep_entry.second, x_com);
59 xmlt::elementst::const_iterator it =
xml.elements.begin();
60 for(; it !=
xml.elements.end(); it++)
66 else if(it->name==
"named_sub")
70 std::string named_name = it->get_attribute(
"name");
73 else if(it->name==
"sub")
79 else if(it->name==
"comment")
83 std::string named_name = it->get_attribute(
"name");
89 std::cout <<
"Unknown sub found (" << it->name <<
"); malformed xml?";
99 result.
name =
"location";
There are a large number of kinds of tree structured or tree-like data in CPROVER.
void move_to_named_sub(const irep_idt &name, irept &irep)
const std::string & id_string() const
static bool is_comment(const irep_idt &name)
void move_to_sub(irept &irep)
const irep_idt & id() const
named_subt & get_named_sub()
const irep_idt & get_column() const
const irep_idt & get_function() const
const irep_idt & get_working_directory() const
const irep_idt & get_file() const
const irep_idt & get_line() const
void set_attribute(const std::string &attribute, unsigned value)
const std::string & id2string(const irep_idt &d)
xmlt xml(const irep_idt &property_id, const property_infot &property_info)
void convert(const irept &irep, xmlt &xml)
xmlt xml(const source_locationt &location)