19 const auto &values = expr.
values();
23 "let must have the type of the 'where' operand");
26 for(
auto &binding :
make_range(variables).zip(values))
29 binding.first.type() == binding.second.type(),
30 "let value must have the type of the let symbol");
41 for(
auto &value : values)
55 const auto &identifier = binding.first.identifier();
58 if(binding.first.is_boolean())
60 DATA_INVARIANT(binding.second.size() == 1,
"boolean values have one bit");
61 symbols[identifier] = binding.second[0];
97 const auto &type = entry.type();
99 symbols.erase(entry.identifier());
bool has_byte_operator(const exprt &src)
Return true iff src or one of its operands contain a byte extract or byte update expression.
Expression classes for byte-level operators.
exprt lower_byte_operators(const exprt &src, const namespacet &ns)
Rewrite an expression possibly containing byte-extract or -update expressions to more fundamental ope...
ait supplies three of the four components needed: an abstract interpreter (in this case handling func...
void record_array_let_binding(const symbol_exprt &symbol, const exprt &value)
Record that symbol is equal to value for the purposes of the array theory.
void erase_literals(const irep_idt &identifier, const typet &type)
void set_literals(const irep_idt &identifier, const typet &type, const bvt &literals)
virtual std::optional< std::size_t > get_width_opt(const typet &type) const
virtual const bvt & convert_bv(const exprt &expr, const std::optional< std::size_t > expected_width={})
Convert expression to vector of literalts, using an internal cache to speed up conversion if availabl...
virtual bvt convert_let(const let_exprt &)
binding_exprt::variablest fresh_binding(const binding_exprt &)
create new, unique variables for the given binding
bool is_unbounded_array(const typet &type) const override
Base class for all expressions.
typet & type()
Return the type of the expression.
binding_exprt::variablest & variables()
convenience accessor for binding().variables()
exprt & where()
convenience accessor for binding().where()
binding_exprt & binding()
Replace a symbol expression by a given expression.
void insert(const class symbol_exprt &old_expr, const exprt &new_expr)
Sets old_expr to be replaced by new_expr if we don't already have a replacement; otherwise does nothi...
std::vector< literalt > bvt
Ranges: pair of begin and end iterators, which can be initialized from containers,...
ranget< iteratort > make_range(iteratort begin, iteratort end)
#define DATA_INVARIANT(CONDITION, REASON)
This condition should be used to document that assumptions that are made on goto_functions,...
API to expression classes.
const array_typet & to_array_type(const typet &type)
Cast a typet to an array_typet.