IDA C++ SDK 9.2
Loading...
Searching...
No Matches
citem_t Struct Reference

Basic ctree item. More...

#include <hexrays.hpp>

Inheritance diagram for citem_t:
cexpr_t cinsn_t carg_t ccase_t

Public Member Functions

 citem_t (ctype_t o=cot_empty)
void swap (citem_t &r)
 Swap two citem_t.
bool is_expr () const
 Is an expression?
bool hexapi contains_expr (const cexpr_t *e) const
 Does the item contain an expression?
bool hexapi contains_label () const
 Does the item contain a label?
const citem_t *hexapi find_parent_of (const citem_t *item) const
 Find parent of the specified item.
citem_tfind_parent_of (const citem_t *item)
citem_t *hexapi find_closest_addr (ea_t _ea)
void print1 (qstring *vout, const cfunc_t *func) const
 Print item into one line.
 ~citem_t ()

Public Attributes

ea_t ea = BADADDR
 address that corresponds to the item. may be BADADDR
ctype_t op
 item type
int label_num = -1
 label number.
int index = -1
 an index in cfunc_t::treeitems.

Detailed Description

Basic ctree item.

This is an abstract class (but we don't use virtual functions in ctree, so the compiler will not disallow you to create citem_t instances). However, items of pure citem_t type must never be created. Two classes, cexpr_t and cinsn_t are derived from it.

Constructor & Destructor Documentation

◆ citem_t()

citem_t::citem_t ( ctype_t o = cot_empty)
inline

◆ ~citem_t()

citem_t::~citem_t ( )
inline

Member Function Documentation

◆ swap()

void citem_t::swap ( citem_t & r)
inline

Swap two citem_t.

◆ is_expr()

bool citem_t::is_expr ( ) const
inline

Is an expression?

◆ contains_expr()

bool citem_t::contains_expr ( const cexpr_t * e) const
inline

Does the item contain an expression?

◆ contains_label()

bool citem_t::contains_label ( ) const
inline

Does the item contain a label?

◆ find_parent_of() [1/2]

const citem_t * citem_t::find_parent_of ( const citem_t * item) const
inline

Find parent of the specified item.

Parameters
itemItem to find the parent of. The search will be performed among the children of the item pointed by this.
Returns
nullptr if not found

◆ find_parent_of() [2/2]

citem_t * citem_t::find_parent_of ( const citem_t * item)
inline

◆ find_closest_addr()

citem_t * citem_t::find_closest_addr ( ea_t _ea)
inline

◆ print1()

void citem_t::print1 ( qstring * vout,
const cfunc_t * func ) const
inline

Print item into one line.

Parameters
voutoutput buffer
funcparent function. This argument is used to find out the referenced variable names.
Returns
length of the generated text.

Member Data Documentation

◆ ea

ea_t citem_t::ea = BADADDR

address that corresponds to the item. may be BADADDR

◆ op

ctype_t citem_t::op

item type

◆ label_num

int citem_t::label_num = -1

label number.

-1 means no label. items of the expression types (cot_...) should not have labels at the final maturity level, but at the intermediate levels any ctree item may have a label. Labels must be unique. Usually they correspond to the basic block numbers.

◆ index

int citem_t::index = -1
mutable

an index in cfunc_t::treeitems.

meaningful only after print_func()


The documentation for this struct was generated from the following file: