16static bool by_length(
const std::string &lhs,
const std::string &rhs)
18 if(lhs.size() < rhs.size())
20 if(lhs.size() > rhs.size())
16static bool by_length(
const std::string &lhs,
const std::string &rhs) {
…}
30 std::vector<std::string> output_values;
31 for(
const auto &value :
values)
33 std::ostringstream
ss;
35 output_values.emplace_back(
ss.str());
37 std::sort(output_values.begin(), output_values.end(),
by_length);
39 join_strings(out, output_values.begin(), output_values.end(),
", ");
47 std::dynamic_pointer_cast<const abstract_value_objectt>(
first())
56 for(
const auto &value :
values)
59 std::dynamic_pointer_cast<const abstract_value_objectt>(value);
static bool by_length(const std::string &lhs, const std::string &rhs)
an unordered set of value objects
void output(std::ostream &out, const ai_baset &ai, const namespacet &ns) const
abstract_object_pointert first() const
constant_interval_exprt to_interval() const
Calculate the set of values as an interval.
This is the basic interface of the abstract interpreter with default implementations of the core func...
virtual void output(const namespacet &ns, const irep_idt &function_id, const goto_programt &goto_program, std::ostream &out) const
Output the abstract states for a single function.
ait supplies three of the four components needed: an abstract interpreter (in this case handling func...
Represents an interval of values.
static exprt get_max(const exprt &a, const exprt &b)
static exprt get_min(const exprt &a, const exprt &b)
Base class for all expressions.
The Boolean constant false.
A namespacet is essentially one or two symbol tables bound together, to allow for symbol lookups in t...
The Boolean constant true.
#define PRECONDITION(CONDITION)
Stream & join_strings(Stream &&os, const It b, const It e, const Delimiter &delimiter, TransformFunc &&transform_func)
Prints items to an stream, separated by a constant delimiter.