IDA C++ SDK 9.2
|
A helper ctree traversal class that maintains parent information. More...
#include <hexrays.hpp>
Public Member Functions | |
ctree_parentee_t (bool post=false) | |
bool hexapi | recalc_parent_types () |
Recalculate type of parent nodes. | |
Public Member Functions inherited from ctree_visitor_t | |
bool | maintain_parents () const |
Should the parent information by maintained? | |
bool | must_prune () const |
Should the traversal skip the children of the current item? | |
bool | must_restart () const |
Should the traversal restart? | |
bool | is_postorder () const |
Should the leave...() functions be called? | |
bool | only_insns () const |
Should all expressions be automatically pruned? | |
void | prune_now () |
Prune children. | |
void | clr_prune () |
Do not prune children. This is an internal function, no need to call it. | |
void | set_restart () |
Restart the travesal. Meaningful only in apply_to_exprs() | |
void | clr_restart () |
Do not restart. This is an internal function, no need to call it. | |
ctree_visitor_t (int _flags) | |
Constructor. | |
virtual | ~ctree_visitor_t () |
int hexapi | apply_to (citem_t *item, citem_t *parent) |
Traverse ctree. | |
int hexapi | apply_to_exprs (citem_t *item, citem_t *parent) |
Traverse only expressions. | |
citem_t * | parent_item () |
Get parent of the current item as an item (statement or expression) | |
cexpr_t * | parent_expr () |
Get parent of the current item as an expression. | |
cinsn_t * | parent_insn () |
Get parent of the current item as a statement. | |
virtual int idaapi | visit_insn (cinsn_t *) |
Visit a statement. | |
virtual int idaapi | visit_expr (cexpr_t *) |
Visit an expression. | |
virtual int idaapi | leave_insn (cinsn_t *) |
Visit a statement after having visited its children. | |
virtual int idaapi | leave_expr (cexpr_t *) |
Visit an expression after having visited its children. |
Additional Inherited Members | |
Public Attributes inherited from ctree_visitor_t | |
int | cv_flags |
Ctree visitor property bits | |
parents_t | parents |
Vector of parents of the current item. | |
cblock_posvec_t | bposvec |
Vector of block positions. |
A helper ctree traversal class that maintains parent information.
|
inline |
|
inline |
Recalculate type of parent nodes.
If a node type has been changed, the visitor must recalculate all parent types, otherwise the ctree becomes inconsistent. If during this recalculation a parent node is added/deleted, this function returns true. In this case the traversal must be stopped because the information about parent nodes is stale.