7 #ifndef RETDEC_LLVMIR2HLL_SUPPORT_STATEMENTS_COUNTER_H
8 #define RETDEC_LLVMIR2HLL_SUPPORT_STATEMENTS_COUNTER_H
A visitor that visits everything in an ordered way.
Definition: ordered_all_visitor.h:44
Counter of the number of statements in a block.
Definition: statements_counter.h:24
bool includeEmptyStmts
Should we also count empty statements?
Definition: statements_counter.h:117
virtual void visit(ShPtr< GlobalVarDef > varDef) override
Definition: statements_counter.cpp:79
bool recursive
Should we also visit nested statements (in compound statements)?
Definition: statements_counter.h:114
static unsigned count(ShPtr< Statement > block, bool recursive=true, bool includeEmptyStmts=false)
Returns the number of statements in block.
Definition: statements_counter.cpp:55
StatementsCounter()
Constructs a new statements counter.
Definition: statements_counter.cpp:45
unsigned countInternal(ShPtr< Statement > block, bool recursive, bool includeEmptyStmts)
Internal implementation of count().
Definition: statements_counter.cpp:66
unsigned numOfStmts
Counter of the number of statements.
Definition: statements_counter.h:111
A mixin to make classes non-copyable.
Definition: non_copyable.h:27
A library providing API for working with back-end IR.
std::shared_ptr< T > ShPtr
An alias for a shared pointer.
Definition: smart_ptr.h:18
Definition: archive_wrapper.h:19
A mixin to make classes non-copyable.
A visitor that visits everything in an ordered way.
Declarations, aliases, macros, etc. for the use of smart pointers.