Go to the documentation of this file.
10 #ifndef CPROVER_UTIL_REPLACE_SYMBOL_H
11 #define CPROVER_UTIL_REPLACE_SYMBOL_H
21 #include <unordered_map>
30 typedef std::unordered_map<irep_idt, exprt>
expr_mapt;
36 const exprt &new_expr);
69 expr_mapt::iterator
erase(expr_mapt::iterator it)
153 #endif // CPROVER_UTIL_REPLACE_SYMBOL_H
dstringt has one field, an unsigned integer no which is an index into a static table of strings.
Replace symbols with constants while maintaining syntactically valid expressions.
virtual ~replace_symbolt()
bool have_to_replace(const exprt &dest) const
bool replaces_symbol(const irep_idt &id) const
~set_require_lvalue_and_backupt()
The type of an expression, extends irept.
expr_mapt::iterator erase(expr_mapt::iterator it)
std::unordered_map< irep_idt, exprt > expr_mapt
const expr_mapt & get_expr_map() const
Base class for all expressions.
Expression to hold a symbol (variable)
expr_mapt & get_expr_map()
set_require_lvalue_and_backupt(bool &require_lvalue, const bool value)
virtual bool replace_symbol_expr(symbol_exprt &dest) const
void operator()(typet &dest) const
bool replace(exprt &dest) const override
void operator()(exprt &dest) const
unchecked_replace_symbolt()
virtual bool replace(exprt &dest) const
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::set< irep_idt > bindings
void insert(const symbol_exprt &old_expr, const exprt &new_expr)
std::size_t erase(const irep_idt &id)
bool replace_symbol_expr(symbol_exprt &dest) const override
bool replace_symbol_expr(symbol_exprt &dest) const override
void set(const class symbol_exprt &old_expr, const exprt &new_expr)
Sets old_expr to be replaced by new_expr.
Replace a symbol expression by a given expression.