45 std::string result =
from_expr(ns,
id, expr);
78 const auto width =
bv_type->get_width();
96 dest=
xmlt(
"goto_trace");
115 xml_failure.set_attribute_bool(
"hidden", step.hidden);
116 xml_failure.set_attribute(
"thread", std::to_string(step.thread_nr));
117 xml_failure.set_attribute(
"step_nr", std::to_string(step.step_nr));
159 if(step.full_lhs.is_not_nil())
166 xml_assignment.set_attribute(
"thread", std::to_string(step.thread_nr));
167 xml_assignment.set_attribute(
"step_nr", std::to_string(step.step_nr));
171 step.assignment_type ==
187 xml_output.set_attribute_bool(
"hidden", step.hidden);
188 xml_output.set_attribute(
"thread", std::to_string(step.thread_nr));
189 xml_output.set_attribute(
"step_nr", std::to_string(step.step_nr));
194 for(
const auto &arg : step.io_args)
198 xml_output.new_element(
"value_expression").new_element(
xml(arg, ns));
208 xml_input.set_attribute_bool(
"hidden", step.hidden);
209 xml_input.set_attribute(
"thread", std::to_string(step.thread_nr));
210 xml_input.set_attribute(
"step_nr", std::to_string(step.step_nr));
212 for(
const auto &arg : step.io_args)
216 xml_input.new_element(
"value_expression").new_element(
xml(arg, ns));
226 std::string tag =
"function_call";
230 xml_call_return.set_attribute(
"thread", std::to_string(step.thread_nr));
231 xml_call_return.set_attribute(
"step_nr", std::to_string(step.step_nr));
247 std::string tag =
"function_return";
251 xml_call_return.set_attribute(
"thread", std::to_string(step.thread_nr));
252 xml_call_return.set_attribute(
"step_nr", std::to_string(step.step_nr));
ait supplies three of the four components needed: an abstract interpreter (in this case handling func...
dstringt has one field, an unsigned integer no which is an index into a static table of strings.
Base class for all expressions.
typet & type()
Return the type of the expression.
Step of the trace of a GOTO program.
std::optional< symbol_exprt > get_lhs_object() const
const irep_idt & id() const
A namespacet is essentially one or two symbol tables bound together, to allow for symbol lookups in t...
bool lookup(const irep_idt &name, const symbolt *&symbol) const override
See documentation for namespace_baset::lookup().
const irep_idt & get_file() const
source_locationt location
Source code location of definition of symbol.
irep_idt name
The unique identifier.
irep_idt irep_idt base_name
Name of module the symbol belongs to.
const irep_idt & display_name() const
Return language specific display name if present.
irep_idt mode
Language mode.
xmlt & new_element(const std::string &key)
static bool is_printable_xml(const std::string &s)
Determine whether s does not contain any characters that cannot be escaped in XML 1....
const std::string & id2string(const irep_idt &d)
std::string from_expr(const namespacet &ns, const irep_idt &identifier, const exprt &expr)
std::string from_type(const namespacet &ns, const irep_idt &identifier, const typet &type)
const std::string integer2binary(const mp_integer &n, std::size_t width)
xmlt xml(const irep_idt &property_id, const property_infot &property_info)
const string_constantt & to_string_constant(const exprt &expr)
std::string default_step_name(const default_step_kindt &step_type)
Turns a default_step_kindt into a string that can be used in the trace.
std::optional< default_trace_stept > default_step(const goto_trace_stept &step, const source_locationt &previous_source_location)
Utilities for printing location info steps in the trace in a format agnostic way.
xmlt full_lhs_value(const goto_trace_stept &step, const namespacet &ns)
static std::string get_printable_xml(const namespacet &ns, const irep_idt &id, const exprt &expr)
Given an expression expr, produce a string representation that is printable in XML 1....
static void replace_string_constants_rec(exprt &expr)
Rewrite all string constants to their array counterparts.
void convert(const namespacet &ns, const goto_tracet &goto_trace, xmlt &dest)