clang 20.0.0git
|
#include "clang/StaticAnalyzer/Core/CheckerManager.h"
Definition at line 126 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckBeginFunctionFunc = CheckerFn<void (CheckerContext &)> |
Definition at line 500 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckBindFunc = CheckerFn<void(SVal location, SVal val, const Stmt *S, CheckerContext &)> |
Definition at line 494 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckBranchConditionFunc = CheckerFn<void (const Stmt *, CheckerContext &)> |
Definition at line 505 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckCallFunc = CheckerFn<void (const CallEvent &, CheckerContext &)> |
Definition at line 488 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckDeadSymbolsFunc = CheckerFn<void (SymbolReaper &, CheckerContext &)> |
Definition at line 511 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckDeclFunc = CheckerFn<void (const Decl *, AnalysisManager&, BugReporter &)> |
Definition at line 470 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckEndAnalysisFunc = CheckerFn<void (ExplodedGraph &, BugReporter &, ExprEngine &)> |
Definition at line 497 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckEndFunctionFunc = CheckerFn<void (const ReturnStmt *, CheckerContext &)> |
Definition at line 502 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckEndOfTranslationUnit = CheckerFn<void (const TranslationUnitDecl *, AnalysisManager &, BugReporter &)> |
Definition at line 535 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckerDtor = CheckerFn<void ()> |
Definition at line 192 of file CheckerManager.h.
Definition at line 190 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckerTag = const void * |
Definition at line 191 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckEventFunc = CheckerFn<void (const void *event)> |
Definition at line 588 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckLiveSymbolsFunc = CheckerFn<void (ProgramStateRef,SymbolReaper &)> |
Definition at line 514 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckLocationFunc = CheckerFn<void(SVal location, bool isLoad, const Stmt *S, CheckerContext &)> |
Definition at line 491 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckNewAllocatorFunc = CheckerFn<void(const CXXAllocatorCall &Call, CheckerContext &)> |
Definition at line 508 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckObjCMessageFunc = CheckerFn<void (const ObjCMethodCall &, CheckerContext &)> |
Definition at line 485 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckPointerEscapeFunc = CheckerFn<ProgramStateRef (ProgramStateRef, const InvalidatedSymbols &Escaped, const CallEvent *Call, PointerEscapeKind Kind, RegionAndSymbolInvalidationTraits *ITraits)> |
Definition at line 524 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckRegionChangesFunc = CheckerFn<ProgramStateRef (ProgramStateRef, const InvalidatedSymbols *symbols, ArrayRef<const MemRegion *> ExplicitRegions, ArrayRef<const MemRegion *> Regions, const LocationContext *LCtx, const CallEvent *Call)> |
Definition at line 516 of file CheckerManager.h.
using clang::ento::CheckerManager::CheckStmtFunc = CheckerFn<void (const Stmt *, CheckerContext &)> |
Definition at line 483 of file CheckerManager.h.
using clang::ento::CheckerManager::EvalAssumeFunc = CheckerFn<ProgramStateRef(ProgramStateRef, SVal cond, bool assumption)> |
Definition at line 530 of file CheckerManager.h.
using clang::ento::CheckerManager::EvalCallFunc = CheckerFn<bool (const CallEvent &, CheckerContext &)> |
Definition at line 533 of file CheckerManager.h.
using clang::ento::CheckerManager::EventTag = void * |
Definition at line 587 of file CheckerManager.h.
using clang::ento::CheckerManager::HandlesDeclFunc = bool (*)(const Decl *D) |
Definition at line 473 of file CheckerManager.h.
using clang::ento::CheckerManager::HandlesStmtFunc = bool (*)(const Stmt *D) |
Definition at line 539 of file CheckerManager.h.
clang::ento::CheckerManager::CheckerManager | ( | ASTContext & | Context, |
AnalyzerOptions & | AOptions, | ||
const Preprocessor & | PP, | ||
ArrayRef< std::string > | plugins, | ||
ArrayRef< std::function< void(CheckerRegistry &)> > | checkerRegistrationFns | ||
) |
Definition at line 20 of file CreateCheckerManager.cpp.
References finishedCheckerRegistration(), and clang::ento::CheckerRegistry::initializeRegistry().
|
inline |
Constructs a CheckerManager that ignores all non TblGen-generated checkers.
Useful for unit testing, unless the checker infrastructure itself is tested.
Definition at line 150 of file CheckerManager.h.
clang::ento::CheckerManager::CheckerManager | ( | AnalyzerOptions & | AOptions, |
const LangOptions & | LangOpts, | ||
DiagnosticsEngine & | Diags, | ||
ArrayRef< std::string > | plugins | ||
) |
Constructs a CheckerManager without requiring an AST.
No checker registration will take place. Only useful when one needs to print the help flags through CheckerRegistryData, and the AST is unavailable.
Definition at line 34 of file CreateCheckerManager.cpp.
References clang::ento::CheckerRegistry::initializeRegistry().
clang::ento::CheckerManager::~CheckerManager | ( | ) |
Definition at line 44 of file CreateCheckerManager.cpp.
|
inline |
Definition at line 603 of file CheckerManager.h.
Referenced by clang::ento::EventDispatcher< EVENT >::dispatchEvent().
|
inline |
Definition at line 597 of file CheckerManager.h.
Referenced by clang::ento::EventDispatcher< EVENT >::_register().
void CheckerManager::_registerForBeginFunction | ( | CheckBeginFunctionFunc | checkfn | ) |
Definition at line 850 of file CheckerManager.cpp.
Referenced by clang::ento::check::BeginFunction::_register().
void CheckerManager::_registerForBind | ( | CheckBindFunc | checkfn | ) |
Definition at line 842 of file CheckerManager.cpp.
Referenced by clang::ento::check::Bind::_register().
void CheckerManager::_registerForBody | ( | CheckDeclFunc | checkfn | ) |
Definition at line 799 of file CheckerManager.cpp.
Referenced by clang::ento::check::ASTCodeBody::_register().
void CheckerManager::_registerForBranchCondition | ( | CheckBranchConditionFunc | checkfn | ) |
Definition at line 858 of file CheckerManager.cpp.
Referenced by clang::ento::check::BranchCondition::_register().
void CheckerManager::_registerForConstPointerEscape | ( | CheckPointerEscapeFunc | checkfn | ) |
Definition at line 883 of file CheckerManager.cpp.
void CheckerManager::_registerForDeadSymbols | ( | CheckDeadSymbolsFunc | checkfn | ) |
Definition at line 871 of file CheckerManager.cpp.
Referenced by clang::ento::check::DeadSymbols::_register().
void CheckerManager::_registerForDecl | ( | CheckDeclFunc | checkfn, |
HandlesDeclFunc | isForDeclFn | ||
) |
Definition at line 793 of file CheckerManager.cpp.
Referenced by clang::ento::check::ASTDecl< DECL >::_register().
void CheckerManager::_registerForEndAnalysis | ( | CheckEndAnalysisFunc | checkfn | ) |
Definition at line 846 of file CheckerManager.cpp.
Referenced by clang::ento::check::EndAnalysis::_register().
void CheckerManager::_registerForEndFunction | ( | CheckEndFunctionFunc | checkfn | ) |
Definition at line 854 of file CheckerManager.cpp.
Referenced by clang::ento::check::EndFunction::_register().
void CheckerManager::_registerForEndOfTranslationUnit | ( | CheckEndOfTranslationUnit | checkfn | ) |
Definition at line 896 of file CheckerManager.cpp.
Referenced by clang::ento::check::EndOfTranslationUnit::_register().
void CheckerManager::_registerForEvalAssume | ( | EvalAssumeFunc | checkfn | ) |
Definition at line 888 of file CheckerManager.cpp.
Referenced by clang::ento::eval::Assume::_register().
void CheckerManager::_registerForEvalCall | ( | EvalCallFunc | checkfn | ) |
Definition at line 892 of file CheckerManager.cpp.
Referenced by clang::ento::eval::Call::_register().
void CheckerManager::_registerForLiveSymbols | ( | CheckLiveSymbolsFunc | checkfn | ) |
Definition at line 867 of file CheckerManager.cpp.
Referenced by clang::ento::check::LiveSymbols::_register().
void CheckerManager::_registerForLocation | ( | CheckLocationFunc | checkfn | ) |
Definition at line 838 of file CheckerManager.cpp.
Referenced by clang::ento::check::Location::_register().
void CheckerManager::_registerForNewAllocator | ( | CheckNewAllocatorFunc | checkfn | ) |
Definition at line 863 of file CheckerManager.cpp.
Referenced by clang::ento::check::NewAllocator::_register().
void CheckerManager::_registerForObjCMessageNil | ( | CheckObjCMessageFunc | checkfn | ) |
Definition at line 823 of file CheckerManager.cpp.
Referenced by clang::ento::check::ObjCMessageNil::_register().
void CheckerManager::_registerForPointerEscape | ( | CheckPointerEscapeFunc | checkfn | ) |
Definition at line 879 of file CheckerManager.cpp.
Referenced by clang::ento::check::PointerEscape::_register(), and clang::ento::check::ConstPointerEscape::_register().
void CheckerManager::_registerForPostCall | ( | CheckCallFunc | checkfn | ) |
Definition at line 834 of file CheckerManager.cpp.
Referenced by clang::ento::check::PostCall::_register().
void CheckerManager::_registerForPostObjCMessage | ( | CheckObjCMessageFunc | checkfn | ) |
Definition at line 827 of file CheckerManager.cpp.
Referenced by clang::ento::check::PostObjCMessage::_register().
void CheckerManager::_registerForPostStmt | ( | CheckStmtFunc | checkfn, |
HandlesStmtFunc | isForStmtFn | ||
) |
Definition at line 813 of file CheckerManager.cpp.
Referenced by clang::ento::check::PostStmt< STMT >::_register().
void CheckerManager::_registerForPreCall | ( | CheckCallFunc | checkfn | ) |
Definition at line 831 of file CheckerManager.cpp.
Referenced by clang::ento::check::PreCall::_register().
void CheckerManager::_registerForPreObjCMessage | ( | CheckObjCMessageFunc | checkfn | ) |
Definition at line 819 of file CheckerManager.cpp.
Referenced by clang::ento::check::PreObjCMessage::_register().
void CheckerManager::_registerForPreStmt | ( | CheckStmtFunc | checkfn, |
HandlesStmtFunc | isForStmtFn | ||
) |
Definition at line 807 of file CheckerManager.cpp.
Referenced by clang::ento::check::PreStmt< STMT >::_register().
void CheckerManager::_registerForRegionChanges | ( | CheckRegionChangesFunc | checkfn | ) |
Definition at line 875 of file CheckerManager.cpp.
Referenced by clang::ento::check::RegionChanges::_register().
|
inline |
Definition at line 591 of file CheckerManager.h.
Referenced by clang::ento::check::Event< EVENT >::_register().
void CheckerManager::finishedCheckerRegistration | ( | ) |
Definition at line 51 of file CheckerManager.cpp.
Referenced by CheckerManager().
|
inline |
Definition at line 170 of file CheckerManager.h.
|
inline |
Definition at line 179 of file CheckerManager.h.
Definition at line 218 of file CheckerManager.h.
References CHECKER.
Referenced by clang::ento::registerInnerPointerCheckerAux().
|
inline |
Definition at line 175 of file CheckerManager.h.
|
inline |
Definition at line 163 of file CheckerManager.h.
Referenced by clang::ento::registerInnerPointerCheckerAux().
|
inline |
Definition at line 178 of file CheckerManager.h.
Referenced by reportInvalidCheckerOptionValue().
|
inline |
Definition at line 169 of file CheckerManager.h.
|
inline |
Definition at line 171 of file CheckerManager.h.
bool CheckerManager::hasPathSensitiveCheckers | ( | ) | const |
Definition at line 37 of file CheckerManager.cpp.
|
inline |
Used to register checkers.
All arguments are automatically passed through to the checker constructor.
Definition at line 204 of file CheckerManager.h.
References CHECKER.
Referenced by clang::ento::registerCheckerDocumentationChecker().
void CheckerManager::reportInvalidCheckerOptionValue | ( | const CheckerBase * | C, |
StringRef | OptionName, | ||
StringRef | ExpectedValueDesc | ||
) | const |
Emits an error through a DiagnosticsEngine about an invalid user supplied checker option value.
Definition at line 61 of file CheckerManager.cpp.
References clang::C, getDiagnostics(), and clang::DiagnosticsEngine::Report().
Referenced by clang::ento::getConfiguration().
void CheckerManager::runCheckersForBeginFunction | ( | ExplodedNodeSet & | Dst, |
const BlockEdge & | L, | ||
ExplodedNode * | Pred, | ||
ExprEngine & | Eng | ||
) |
Run checkers on beginning of function.
Definition at line 434 of file CheckerManager.cpp.
References clang::C, expandGraphWithCheckers(), and clang::ento::ExplodedNodeSet::insert().
Referenced by clang::ento::ExprEngine::processBeginOfFunction().
void CheckerManager::runCheckersForBind | ( | ExplodedNodeSet & | Dst, |
const ExplodedNodeSet & | Src, | ||
SVal | location, | ||
SVal | val, | ||
const Stmt * | S, | ||
ExprEngine & | Eng, | ||
const ProgramPoint & | PP | ||
) |
Run checkers for binding of a value to a location.
Definition at line 391 of file CheckerManager.cpp.
References clang::C, and expandGraphWithCheckers().
void CheckerManager::runCheckersForBranchCondition | ( | const Stmt * | condition, |
ExplodedNodeSet & | Dst, | ||
ExplodedNode * | Pred, | ||
ExprEngine & | Eng | ||
) |
Run checkers for branch condition.
Definition at line 492 of file CheckerManager.cpp.
References clang::C, clang::Condition, expandGraphWithCheckers(), and clang::ento::ExplodedNodeSet::insert().
Referenced by clang::ento::ExprEngine::processBranch().
void CheckerManager::runCheckersForCallEvent | ( | bool | isPreVisit, |
ExplodedNodeSet & | Dst, | ||
const ExplodedNodeSet & | Src, | ||
const CallEvent & | Call, | ||
ExprEngine & | Eng, | ||
bool | wasInlined = false |
||
) |
Run checkers for visiting obj-c messages.
Run checkers for visiting an abstract call event.
Definition at line 296 of file CheckerManager.cpp.
References clang::C, clang::Call, and expandGraphWithCheckers().
Referenced by runCheckersForPostCall(), and runCheckersForPreCall().
void CheckerManager::runCheckersForDeadSymbols | ( | ExplodedNodeSet & | Dst, |
const ExplodedNodeSet & | Src, | ||
SymbolReaper & | SymReaper, | ||
const Stmt * | S, | ||
ExprEngine & | Eng, | ||
ProgramPoint::Kind | K | ||
) |
Run checkers for dead symbols.
Notifies checkers when symbols become dead. For example, this allows checkers to aggressively clean up/reduce the checker state and produce precise diagnostics.
Definition at line 585 of file CheckerManager.cpp.
References clang::C, and expandGraphWithCheckers().
Referenced by clang::ento::ExprEngine::removeDead().
void CheckerManager::runCheckersForEndAnalysis | ( | ExplodedGraph & | G, |
BugReporter & | BR, | ||
ExprEngine & | Eng | ||
) |
Run checkers for end of analysis.
Definition at line 400 of file CheckerManager.cpp.
Referenced by clang::ento::ExprEngine::processEndWorklist().
void CheckerManager::runCheckersForEndFunction | ( | NodeBuilderContext & | BC, |
ExplodedNodeSet & | Dst, | ||
ExplodedNode * | Pred, | ||
ExprEngine & | Eng, | ||
const ReturnStmt * | RS | ||
) |
Run checkers on end of function.
Run checkers for end of path.
Definition at line 447 of file CheckerManager.cpp.
References clang::C, and clang::ento::ExplodedNode::getLocationContext().
Referenced by clang::ento::ExprEngine::processEndOfFunction().
ProgramStateRef CheckerManager::runCheckersForEvalAssume | ( | ProgramStateRef | state, |
SVal | Cond, | ||
bool | Assumption | ||
) |
Run checkers for handling assumptions on symbolic values.
Definition at line 637 of file CheckerManager.cpp.
Referenced by clang::ento::ExprEngine::processAssume().
void CheckerManager::runCheckersForEvalCall | ( | ExplodedNodeSet & | Dst, |
const ExplodedNodeSet & | Src, | ||
const CallEvent & | Call, | ||
ExprEngine & | Eng, | ||
const EvalCallOptions & | CallOpts | ||
) |
Run checkers for evaluating a call.
Warning: Currently, the CallEvent MUST come from a CallExpr!
Only one checker will evaluate the call.
Definition at line 651 of file CheckerManager.cpp.
References clang::C, clang::Call, clang::ento::ExprEngine::defaultEvalCall(), clang::ento::ExprEngine::getBuilderContext(), clang::ProgramPoint::getProgramPoint(), clang::ento::ExplodedNodeSet::insert(), clang::ento::OS, clang::ProgramPoint::PostStmtKind, and toString().
Referenced by clang::ento::ExprEngine::evalCall().
void CheckerManager::runCheckersForLiveSymbols | ( | ProgramStateRef | state, |
SymbolReaper & | SymReaper | ||
) |
Run checkers for live symbols.
Allows modifying SymbolReaper object. For example, checkers can explicitly register symbols of interest as live. These symbols will not be marked dead and removed.
Definition at line 544 of file CheckerManager.cpp.
Referenced by clang::ento::ExprEngine::removeDead().
void CheckerManager::runCheckersForLocation | ( | ExplodedNodeSet & | Dst, |
const ExplodedNodeSet & | Src, | ||
SVal | location, | ||
bool | isLoad, | ||
const Stmt * | NodeEx, | ||
const Stmt * | BoundEx, | ||
ExprEngine & | Eng | ||
) |
Run checkers for load/store of a location.
Definition at line 348 of file CheckerManager.cpp.
References clang::C, and expandGraphWithCheckers().
void CheckerManager::runCheckersForNewAllocator | ( | const CXXAllocatorCall & | Call, |
ExplodedNodeSet & | Dst, | ||
ExplodedNode * | Pred, | ||
ExprEngine & | Eng, | ||
bool | wasInlined = false |
||
) |
Run checkers between C++ operator new and constructor calls.
Definition at line 532 of file CheckerManager.cpp.
References clang::C, clang::Call, expandGraphWithCheckers(), and clang::ento::ExplodedNodeSet::insert().
Referenced by clang::ento::ExprEngine::processCallExit(), and clang::ento::ExprEngine::VisitCXXNewAllocatorCall().
void CheckerManager::runCheckersForObjCMessage | ( | ObjCMessageVisitKind | visitKind, |
ExplodedNodeSet & | Dst, | ||
const ExplodedNodeSet & | Src, | ||
const ObjCMethodCall & | msg, | ||
ExprEngine & | Eng, | ||
bool | wasInlined = false |
||
) |
Run checkers for visiting obj-c messages.
Definition at line 238 of file CheckerManager.cpp.
References clang::C, and expandGraphWithCheckers().
Referenced by runCheckersForObjCMessageNil(), runCheckersForPostObjCMessage(), and runCheckersForPreObjCMessage().
|
inline |
Run checkers for visiting an obj-c message to nil.
Definition at line 294 of file CheckerManager.h.
References clang::ento::MessageNil, and runCheckersForObjCMessage().
Referenced by clang::ento::ExprEngine::VisitObjCMessage().
ProgramStateRef CheckerManager::runCheckersForPointerEscape | ( | ProgramStateRef | State, |
const InvalidatedSymbols & | Escaped, | ||
const CallEvent * | Call, | ||
PointerEscapeKind | Kind, | ||
RegionAndSymbolInvalidationTraits * | ITraits | ||
) |
Run checkers when pointers escape.
Run checkers to process symbol escape event.
This notifies the checkers about pointer escape, which occurs whenever the analyzer cannot track the symbol any more. For example, as a result of assigning a pointer into a global or when it's passed to a function call the analyzer cannot model.
State | The state at the point of escape. |
Escaped | The list of escaped symbols. |
Call | The corresponding CallEvent, if the symbols escape as parameters to the given call. |
Kind | The reason of pointer escape. |
ITraits | Information about invalidation for a particular region/symbol. |
Definition at line 616 of file CheckerManager.cpp.
References clang::Call, clang::ento::PSK_DirectEscapeOnCall, and clang::ento::PSK_IndirectEscapeOnCall.
Referenced by clang::ento::ExprEngine::notifyCheckersOfPointerEscape().
|
inline |
Run checkers for post-visiting obj-c messages.
Definition at line 316 of file CheckerManager.h.
References clang::Call, and runCheckersForCallEvent().
Referenced by clang::ento::ExprEngine::evalCall(), clang::ento::ExprEngine::processCallExit(), clang::ento::ExprEngine::VisitCXXDeleteExpr(), clang::ento::ExprEngine::VisitCXXDestructor(), clang::ento::ExprEngine::VisitCXXNewAllocatorCall(), and clang::ento::ExprEngine::VisitObjCMessage().
|
inline |
Run checkers for post-visiting obj-c messages.
Definition at line 284 of file CheckerManager.h.
References clang::ento::Post, and runCheckersForObjCMessage().
Referenced by clang::ento::ExprEngine::processCallExit(), and clang::ento::ExprEngine::VisitObjCMessage().
|
inline |
Run checkers for post-visiting Stmts.
The notification is performed for every explored CFGElement, which does not include the control flow statements such as IfStmt.
Definition at line 261 of file CheckerManager.h.
References runCheckersForStmt().
Referenced by clang::ento::ExprEngine::processCallExit(), clang::ento::ExprEngine::Visit(), clang::ento::ExprEngine::VisitArrayInitLoopExpr(), clang::ento::ExprEngine::VisitArraySubscriptExpr(), clang::ento::ExprEngine::VisitAtomicExpr(), clang::ento::ExprEngine::VisitBinaryOperator(), clang::ento::ExprEngine::VisitBlockExpr(), clang::ento::ExprEngine::VisitCallExpr(), clang::ento::ExprEngine::VisitDeclStmt(), clang::ento::ExprEngine::VisitLambdaExpr(), clang::ento::ExprEngine::VisitLvalObjCIvarRefExpr(), clang::ento::ExprEngine::VisitMemberExpr(), clang::ento::ExprEngine::VisitObjCForCollectionStmt(), clang::ento::ExprEngine::VisitUnaryExprOrTypeTraitExpr(), and clang::ento::ExprEngine::VisitUnaryOperator().
|
inline |
Run checkers for pre-visiting obj-c messages.
Definition at line 310 of file CheckerManager.h.
References clang::Call, and runCheckersForCallEvent().
Referenced by clang::ento::ExprEngine::evalCall(), clang::ento::ExprEngine::VisitCXXDeleteExpr(), clang::ento::ExprEngine::VisitCXXDestructor(), clang::ento::ExprEngine::VisitCXXNewAllocatorCall(), and clang::ento::ExprEngine::VisitObjCMessage().
|
inline |
Run checkers for pre-visiting obj-c messages.
Definition at line 276 of file CheckerManager.h.
References clang::ento::Pre, and runCheckersForObjCMessage().
Referenced by clang::ento::ExprEngine::VisitObjCMessage().
|
inline |
Run checkers for pre-visiting Stmts.
The notification is performed for every explored CFGElement, which does not include the control flow statements such as IfStmt.
Definition at line 248 of file CheckerManager.h.
References runCheckersForStmt().
Referenced by clang::ento::ExprEngine::Visit(), clang::ento::ExprEngine::VisitArrayInitLoopExpr(), clang::ento::ExprEngine::VisitArraySubscriptExpr(), clang::ento::ExprEngine::VisitAtomicExpr(), clang::ento::ExprEngine::VisitBinaryOperator(), clang::ento::ExprEngine::VisitCallExpr(), clang::ento::ExprEngine::VisitCast(), clang::ento::ExprEngine::VisitDeclStmt(), clang::ento::ExprEngine::VisitMemberExpr(), clang::ento::ExprEngine::VisitObjCAtSynchronizedStmt(), clang::ento::ExprEngine::VisitReturnStmt(), clang::ento::ExprEngine::VisitUnaryExprOrTypeTraitExpr(), and clang::ento::ExprEngine::VisitUnaryOperator().
void CheckerManager::runCheckersForPrintStateJson | ( | raw_ostream & | Out, |
ProgramStateRef | State, | ||
const char * | NL = "\n" , |
||
unsigned int | Space = 0 , |
||
bool | IsDot = false |
||
) | const |
Run checkers for debug-printing a ProgramState.
Unlike most other callbacks, any checker can simply implement the virtual method CheckerBase::printState if it has custom data to print.
Out | The output stream |
State | The state being printed |
NL | The preferred representation of a newline. |
Space | The preferred space between the left side and the message. |
IsDot | Whether the message will be printed in 'dot' format. |
Definition at line 720 of file CheckerManager.cpp.
References NewLine.
Referenced by clang::ento::ExprEngine::printJson().
ProgramStateRef CheckerManager::runCheckersForRegionChanges | ( | ProgramStateRef | state, |
const InvalidatedSymbols * | invalidated, | ||
ArrayRef< const MemRegion * > | ExplicitRegions, | ||
ArrayRef< const MemRegion * > | Regions, | ||
const LocationContext * | LCtx, | ||
const CallEvent * | Call | ||
) |
Run checkers for region changes.
This corresponds to the check::RegionChanges callback.
state | The current program state. |
invalidated | A set of all symbols potentially touched by the change. |
ExplicitRegions | The regions explicitly requested for invalidation. For example, in the case of a function call, these would be arguments. |
Regions | The transitive closure of accessible regions, i.e. all regions that may have been touched by this change. |
Call | The call expression wrapper if the regions are invalidated by a call. |
Definition at line 597 of file CheckerManager.cpp.
References clang::Call.
Referenced by clang::ento::ExprEngine::processRegionChanges().
void CheckerManager::runCheckersForStmt | ( | bool | isPreVisit, |
ExplodedNodeSet & | Dst, | ||
const ExplodedNodeSet & | Src, | ||
const Stmt * | S, | ||
ExprEngine & | Eng, | ||
bool | wasInlined = false |
||
) |
Run checkers for visiting Stmts.
Definition at line 182 of file CheckerManager.cpp.
References clang::C, and expandGraphWithCheckers().
Referenced by runCheckersForPostStmt(), and runCheckersForPreStmt().
void CheckerManager::runCheckersOnASTBody | ( | const Decl * | D, |
AnalysisManager & | mgr, | ||
BugReporter & | BR | ||
) |
Run checkers handling Decls containing a Stmt body.
Definition at line 96 of file CheckerManager.cpp.
References D, and clang::Decl::hasBody().
void CheckerManager::runCheckersOnASTDecl | ( | const Decl * | D, |
AnalysisManager & | mgr, | ||
BugReporter & | BR | ||
) |
Run checkers handling Decls.
Definition at line 74 of file CheckerManager.cpp.
References D, and clang::Decl::getKind().
void CheckerManager::runCheckersOnEndOfTranslationUnit | ( | const TranslationUnitDecl * | TU, |
AnalysisManager & | mgr, | ||
BugReporter & | BR | ||
) |
Run checkers for the entire Translation Unit.
Definition at line 712 of file CheckerManager.cpp.
|
inline |
Definition at line 162 of file CheckerManager.h.
Referenced by clang::ento::CheckerRegistry::initializeManager().