cprover
|
Allows to: More...
Public Member Functions | |
flag_resett (const goto_programt::instructiont &_instruction) | |
void | set_flag (bool &flag, bool new_value, const irep_idt &flag_name) |
Store the current value of flag and then set its value to new_value . | |
void | disable_flag (bool &flag, const irep_idt &flag_name) |
Sets the given flag to false, overriding any previous value. | |
~flag_resett () | |
Restore the values of all flags that have been modified via set_flag . | |
Private Attributes | |
const goto_programt::instructiont & | instruction |
std::map< bool *, bool > | flags_to_reset |
std::set< bool * > | disabled_flags |
Allows to:
set_flag
disable_flag
, such that previous set_flag
are overridden and future set_flag
are ignored.A flag's initial value (before any set_flag
or disable_flag
) is restored when the entire object goes out of scope.
Definition at line 1940 of file goto_check_c.cpp.
|
inlineexplicit |
Definition at line 1943 of file goto_check_c.cpp.
|
inline |
Restore the values of all flags that have been modified via set_flag
.
Definition at line 1997 of file goto_check_c.cpp.
Sets the given flag to false, overriding any previous value.
disable_flag
after set_flag
overrides the set valuedisable_flag
twice triggers an INVARIANT Definition at line 1975 of file goto_check_c.cpp.
Store the current value of flag
and then set its value to new_value
.
set_flag
after disable_flag
is a no-opset_flag
twice triggers an INVARIANT Definition at line 1953 of file goto_check_c.cpp.
|
private |
Definition at line 2006 of file goto_check_c.cpp.
Definition at line 2005 of file goto_check_c.cpp.
|
private |
Definition at line 2004 of file goto_check_c.cpp.