clang 20.0.0git
Public Member Functions | List of all members
clang::ento::NoStoreFuncVisitor Class Referencefinal

Put a diagnostic on return statement of all inlined functions for which the region of interest RegionOfInterest was passed into, but not written inside, and it has caused an undefined read or a null pointer dereference outside. More...

#include "clang/StaticAnalyzer/Core/BugReporter/BugReporterVisitors.h"

Inheritance diagram for clang::ento::NoStoreFuncVisitor:
Inheritance graph
[legend]

Public Member Functions

 NoStoreFuncVisitor (const SubRegion *R, bugreporter::TrackingKind TKind=bugreporter::TrackingKind::Thorough)
 
void Profile (llvm::FoldingSetNodeID &ID) const override
 
- Public Member Functions inherited from clang::ento::NoStateChangeFuncVisitor
 NoStateChangeFuncVisitor (bugreporter::TrackingKind TKind)
 
PathDiagnosticPieceRef VisitNode (const ExplodedNode *N, BugReporterContext &BR, PathSensitiveBugReport &R) final
 Return a diagnostic piece which should be associated with the given node.
 
- Public Member Functions inherited from clang::ento::BugReporterVisitor
 BugReporterVisitor ()=default
 
 BugReporterVisitor (const BugReporterVisitor &)=default
 
 BugReporterVisitor (BugReporterVisitor &&)
 
BugReporterVisitoroperator= (const BugReporterVisitor &)=delete
 
BugReporterVisitoroperator= (BugReporterVisitor &&)=delete
 
virtual ~BugReporterVisitor ()
 
virtual PathDiagnosticPieceRef VisitNode (const ExplodedNode *Succ, BugReporterContext &BRC, PathSensitiveBugReport &BR)=0
 Return a diagnostic piece which should be associated with the given node.
 
virtual void finalizeVisitor (BugReporterContext &BRC, const ExplodedNode *EndPathNode, PathSensitiveBugReport &BR)
 Last function called on the visitor, no further calls to VisitNode would follow.
 
virtual PathDiagnosticPieceRef getEndPath (BugReporterContext &BRC, const ExplodedNode *N, PathSensitiveBugReport &BR)
 Provide custom definition for the final diagnostic piece on the path - the piece, which is displayed before the path is expanded.
 
virtual void Profile (llvm::FoldingSetNodeID &ID) const =0
 

Additional Inherited Members

- Static Public Member Functions inherited from clang::ento::BugReporterVisitor
static PathDiagnosticPieceRef getDefaultEndPath (const BugReporterContext &BRC, const ExplodedNode *N, const PathSensitiveBugReport &BR)
 Generates the default final diagnostic piece.
 
- Protected Member Functions inherited from clang::ento::NoStateChangeFuncVisitor
virtual bool wasModifiedBeforeCallExit (const ExplodedNode *CurrN, const ExplodedNode *CallExitBeginN)
 
virtual bool wasModifiedInFunction (const ExplodedNode *CallEnterN, const ExplodedNode *CallExitEndN)
 
virtual PathDiagnosticPieceRef maybeEmitNoteForObjCSelf (PathSensitiveBugReport &R, const ObjCMethodCall &Call, const ExplodedNode *N)=0
 Consume the information on the non-modifying stack frame in order to either emit a note or not.
 
virtual PathDiagnosticPieceRef maybeEmitNoteForCXXThis (PathSensitiveBugReport &R, const CXXConstructorCall &Call, const ExplodedNode *N)=0
 Consume the information on the non-modifying stack frame in order to either emit a note or not.
 
virtual PathDiagnosticPieceRef maybeEmitNoteForParameters (PathSensitiveBugReport &R, const CallEvent &Call, const ExplodedNode *N)=0
 Consume the information on the non-modifying stack frame in order to either emit a note or not.
 
- Protected Attributes inherited from clang::ento::NoStateChangeFuncVisitor
bugreporter::TrackingKind TKind
 

Detailed Description

Put a diagnostic on return statement of all inlined functions for which the region of interest RegionOfInterest was passed into, but not written inside, and it has caused an undefined read or a null pointer dereference outside.

Definition at line 725 of file BugReporterVisitors.h.

Constructor & Destructor Documentation

◆ NoStoreFuncVisitor()

clang::ento::NoStoreFuncVisitor::NoStoreFuncVisitor ( const SubRegion R,
bugreporter::TrackingKind  TKind = bugreporter::TrackingKind::Thorough 
)
inline

Definition at line 739 of file BugReporterVisitors.h.

References SM.

Member Function Documentation

◆ Profile()

void clang::ento::NoStoreFuncVisitor::Profile ( llvm::FoldingSetNodeID &  ID) const
inlineoverridevirtual

Implements clang::ento::BugReporterVisitor.

Definition at line 747 of file BugReporterVisitors.h.

References ID.


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