clang 22.0.0git
clang::AnalysisDeclContextManager Class Reference

#include "clang/Analysis/AnalysisDeclContext.h"

Public Member Functions

 AnalysisDeclContextManager (ASTContext &ASTCtx, bool useUnoptimizedCFG=false, bool addImplicitDtors=false, bool addInitializers=false, bool addTemporaryDtors=false, bool addLifetime=false, bool addLoopExit=false, bool addScopes=false, bool synthesizeBodies=false, bool addStaticInitBranches=false, bool addCXXNewAllocator=true, bool addRichCXXConstructors=true, bool markElidedCXXConstructors=true, bool addVirtualBaseBranches=true, std::unique_ptr< CodeInjector > injector=nullptr)
AnalysisDeclContextgetContext (const Decl *D)
bool getUseUnoptimizedCFG () const
CFG::BuildOptionsgetCFGBuildOptions ()
bool synthesizeBodies () const
const StackFrameContextgetStackFrame (const Decl *D)
 Obtain the beginning context of the analysis.
const StackFrameContextgetStackFrame (AnalysisDeclContext *ADC, const LocationContext *Parent, const Stmt *S, const CFGBlock *Block, unsigned BlockCount, unsigned Index)
 Obtain a context of the call stack using its parent context.
BodyFarmgetBodyFarm ()
void clear ()
 Discard all previously created AnalysisDeclContexts.

Friends

class AnalysisDeclContext

Detailed Description

Definition at line 425 of file AnalysisDeclContext.h.

Constructor & Destructor Documentation

◆ AnalysisDeclContextManager()

AnalysisDeclContextManager::AnalysisDeclContextManager ( ASTContext & ASTCtx,
bool useUnoptimizedCFG = false,
bool addImplicitDtors = false,
bool addInitializers = false,
bool addTemporaryDtors = false,
bool addLifetime = false,
bool addLoopExit = false,
bool addScopes = false,
bool synthesizeBodies = false,
bool addStaticInitBranches = false,
bool addCXXNewAllocator = true,
bool addRichCXXConstructors = true,
bool markElidedCXXConstructors = true,
bool addVirtualBaseBranches = true,
std::unique_ptr< CodeInjector > injector = nullptr )

Definition at line 66 of file AnalysisDeclContext.cpp.

References synthesizeBodies().

Member Function Documentation

◆ clear()

void AnalysisDeclContextManager::clear ( )

Discard all previously created AnalysisDeclContexts.

Definition at line 89 of file AnalysisDeclContext.cpp.

◆ getBodyFarm()

BodyFarm & AnalysisDeclContextManager::getBodyFarm ( )

Definition at line 306 of file AnalysisDeclContext.cpp.

◆ getCFGBuildOptions()

CFG::BuildOptions & clang::AnalysisDeclContextManager::getCFGBuildOptions ( )
inline

Definition at line 462 of file AnalysisDeclContext.h.

◆ getContext()

AnalysisDeclContext * AnalysisDeclContextManager::getContext ( const Decl * D)

◆ getStackFrame() [1/2]

const StackFrameContext * clang::AnalysisDeclContextManager::getStackFrame ( AnalysisDeclContext * ADC,
const LocationContext * Parent,
const Stmt * S,
const CFGBlock * Block,
unsigned BlockCount,
unsigned Index )
inline

Obtain a context of the call stack using its parent context.

Parameters
ADCThe AnalysisDeclContext.
ParentLCThe parent context of this newly created context.
SThe call.
BlockThe basic block.
BlockCountThe current count of entering into Blk.
IndexThe index of Blk.
Returns
The context for D with parent context ParentLC.

Definition at line 476 of file AnalysisDeclContext.h.

References AnalysisDeclContext, clang::Block, and clang::LocationContext::getStackFrame().

◆ getStackFrame() [2/2]

const StackFrameContext * clang::AnalysisDeclContextManager::getStackFrame ( const Decl * D)
inline

Obtain the beginning context of the analysis.

Returns
The top level stack frame for D.

Definition at line 470 of file AnalysisDeclContext.h.

References getContext(), and clang::LocationContext::getStackFrame().

Referenced by clang::ento::CallEvent::getCalleeStackFrame().

◆ getUseUnoptimizedCFG()

bool clang::AnalysisDeclContextManager::getUseUnoptimizedCFG ( ) const
inline

Definition at line 458 of file AnalysisDeclContext.h.

◆ synthesizeBodies()

bool clang::AnalysisDeclContextManager::synthesizeBodies ( ) const
inline
Returns
Whether faux bodies should be synthesized for known functions.

Definition at line 465 of file AnalysisDeclContext.h.

Referenced by AnalysisDeclContextManager().

◆ AnalysisDeclContext

friend class AnalysisDeclContext
friend

Definition at line 489 of file AnalysisDeclContext.h.

References AnalysisDeclContext.

Referenced by AnalysisDeclContext, getContext(), and getStackFrame().


The documentation for this class was generated from the following files: