|
cprover
|
Wrapper for functions removing dereferences in expressions contained in a goto program. More...
#include <goto_program_dereference.h>
Inheritance diagram for goto_program_dereferencet:
Collaboration diagram for goto_program_dereferencet:Public Member Functions | |
| goto_program_dereferencet (const namespacet &_ns, symbol_tablet &_new_symbol_table, const optionst &_options, value_setst &_value_sets) | |
| void | dereference_program (goto_programt &goto_program, bool checks_only=false) |
| void | dereference_program (goto_functionst &goto_functions, bool checks_only=false) |
| void | dereference_expression (const irep_idt &function_id, goto_programt::const_targett target, exprt &expr) |
Set the current target to target and remove derefence from expr. More... | |
| virtual | ~goto_program_dereferencet () |
Protected Member Functions | |
| const symbolt * | get_or_create_failed_symbol (const exprt &expr) override |
| void | get_value_set (const exprt &expr, value_setst::valuest &dest) const override |
Gets the value set corresponding to the current target and expression expr. More... | |
| std::vector< exprt > | get_value_set (const exprt &expr) const override |
Gets the value set corresponding to the current target and expression expr. More... | |
| void | dereference_instruction (goto_programt::targett target, bool checks_only=false) |
Remove dereference from expressions contained in the instruction at target. More... | |
| void | dereference_rec (exprt &expr) |
Turn subexpression of expr of the form &*p into p and use dereference on subexpressions of the form *p More... | |
| void | dereference_expr (exprt &expr, const bool checks_only) |
Remove dereference expressions contained in expr. More... | |
Protected Member Functions inherited from dereference_callbackt | |
| virtual | ~dereference_callbackt ()=default |
Protected Attributes | |
| const optionst & | options |
| const namespacet & | ns |
| value_setst & | value_sets |
| value_set_dereferencet | dereference |
| irep_idt | current_function |
| goto_programt::const_targett | current_target |
| goto_programt | new_code |
Wrapper for functions removing dereferences in expressions contained in a goto program.
Definition at line 24 of file goto_program_dereference.h.
|
inline |
Definition at line 31 of file goto_program_dereference.h.
|
inlinevirtual |
Definition at line 56 of file goto_program_dereference.h.
|
protected |
Remove dereference expressions contained in expr.
| expr | an expression |
| checks_only | when true, execute the substitution on a copy of expr so that expr stays unchanged. In that case the only observable effect is whether an exception would be thrown. |
Definition at line 154 of file goto_program_dereference.cpp.
| void goto_program_dereferencet::dereference_expression | ( | const irep_idt & | function_id, |
| goto_programt::const_targett | target, | ||
| exprt & | expr | ||
| ) |
Set the current target to target and remove derefence from expr.
Definition at line 272 of file goto_program_dereference.cpp.
|
protected |
Remove dereference from expressions contained in the instruction at target.
If check_only is true, the dereferencing is performed on copies of the expressions, in that case the only observable effect is whether an exception would be thrown.
Definition at line 204 of file goto_program_dereference.cpp.
| void goto_program_dereferencet::dereference_program | ( | goto_functionst & | goto_functions, |
| bool | checks_only = false |
||
| ) |
Definition at line 189 of file goto_program_dereference.cpp.
| void goto_program_dereferencet::dereference_program | ( | goto_programt & | goto_program, |
| bool | checks_only = false |
||
| ) |
Definition at line 167 of file goto_program_dereference.cpp.
|
protected |
Turn subexpression of expr of the form &*p into p and use dereference on subexpressions of the form *p
| expr | expression in which to remove dereferences |
Definition at line 48 of file goto_program_dereference.cpp.
|
overrideprotectedvirtual |
| expr | expression to check |
expr, or nullptr if none Implements dereference_callbackt.
Definition at line 23 of file goto_program_dereference.cpp.
|
overrideprotectedvirtual |
Gets the value set corresponding to the current target and expression expr.
| expr | an expression |
Implements dereference_callbackt.
Definition at line 144 of file goto_program_dereference.cpp.
|
overrideprotectedvirtual |
Gets the value set corresponding to the current target and expression expr.
| expr | an expression | |
| [out] | dest | gets the value set |
Implements dereference_callbackt.
Definition at line 132 of file goto_program_dereference.cpp.
|
protected |
Definition at line 82 of file goto_program_dereference.h.
|
protected |
Definition at line 83 of file goto_program_dereference.h.
|
protected |
Definition at line 64 of file goto_program_dereference.h.
|
protected |
Definition at line 84 of file goto_program_dereference.h.
|
protected |
Definition at line 62 of file goto_program_dereference.h.
|
protected |
Definition at line 61 of file goto_program_dereference.h.
|
protected |
Definition at line 63 of file goto_program_dereference.h.