clang  8.0.0svn
Public Member Functions | Static Public Member Functions | Protected Types | Protected Member Functions | Friends | List of all members
clang::CXXDestructorCall Class Reference

Represents an implicit call to a C++ destructor. More...

#include "clang/StaticAnalyzer/Core/PathSensitive/CallEvent.h"

Inheritance diagram for clang::CXXDestructorCall:
Inheritance graph
[legend]
Collaboration diagram for clang::CXXDestructorCall:
Collaboration graph
[legend]

Public Member Functions

SourceRange getSourceRange () const override
 
unsigned getNumArgs () const override
 
RuntimeDefinition getRuntimeDefinition () const override
 
SVal getCXXThisVal () const override
 Returns the value of the implicit 'this' object. More...
 
bool isBaseDestructor () const
 Returns true if this is a call to a base class destructor. More...
 
Kind getKind () const override
 
- Public Member Functions inherited from clang::CXXInstanceCall
virtual const ExprgetCXXThisExpr () const
 Returns the expression representing the implicit 'this' object. More...
 
const FunctionDeclgetDecl () const override
 
RuntimeDefinition getRuntimeDefinition () const override
 
void getInitialStackFrameContents (const StackFrameContext *CalleeCtx, BindingsTy &Bindings) const override
 

Static Public Member Functions

static bool classof (const CallEvent *CA)
 
- Static Public Member Functions inherited from clang::CXXInstanceCall
static bool classof (const CallEvent *CA)
 

Protected Types

using DtorDataTy = llvm::PointerIntPair< const MemRegion *, 1, bool >
 

Protected Member Functions

 CXXDestructorCall (const CXXDestructorDecl *DD, const Stmt *Trigger, const MemRegion *Target, bool IsBaseDestructor, ProgramStateRef St, const LocationContext *LCtx)
 Creates an implicit destructor. More...
 
 CXXDestructorCall (const CXXDestructorCall &Other)=default
 
void cloneTo (void *Dest) const override
 
- Protected Member Functions inherited from clang::CXXInstanceCall
 CXXInstanceCall (const CallExpr *CE, ProgramStateRef St, const LocationContext *LCtx)
 
 CXXInstanceCall (const FunctionDecl *D, ProgramStateRef St, const LocationContext *LCtx)
 
 CXXInstanceCall (const CXXInstanceCall &Other)=default
 
void getExtraInvalidatedValues (ValueList &Values, RegionAndSymbolInvalidationTraits *ETraits) const override
 

Friends

class CallEventManager
 

Detailed Description

Represents an implicit call to a C++ destructor.

This can occur at the end of a scope (for automatic objects), at the end of a full-expression (for temporaries), or as part of a delete.

Definition at line 811 of file CallEvent.h.

Member Typedef Documentation

◆ DtorDataTy

using clang::CXXDestructorCall::DtorDataTy = llvm::PointerIntPair<const MemRegion *, 1, bool>
protected

Definition at line 815 of file CallEvent.h.

Constructor & Destructor Documentation

◆ CXXDestructorCall() [1/2]

clang::CXXDestructorCall::CXXDestructorCall ( const CXXDestructorDecl DD,
const Stmt Trigger,
const MemRegion *  Target,
bool  IsBaseDestructor,
ProgramStateRef  St,
const LocationContext LCtx 
)
inlineprotected

Creates an implicit destructor.

Parameters
DDThe destructor that will be called.
TriggerThe statement whose completion causes this destructor call.
TargetThe object region to be destructed.
StThe path-sensitive state at this point in the program.
LCtxThe location context at this point in the program.

Definition at line 824 of file CallEvent.h.

References clang::Stmt::getEndLoc().

◆ CXXDestructorCall() [2/2]

clang::CXXDestructorCall::CXXDestructorCall ( const CXXDestructorCall Other)
protecteddefault

Member Function Documentation

◆ classof()

static bool clang::CXXDestructorCall::classof ( const CallEvent CA)
inlinestatic

Definition at line 852 of file CallEvent.h.

References clang::ento::CE_CXXDestructor.

◆ cloneTo()

void clang::CXXDestructorCall::cloneTo ( void *  Dest) const
inlineoverrideprotected

Definition at line 834 of file CallEvent.h.

◆ getCXXThisVal()

SVal CXXDestructorCall::getCXXThisVal ( ) const
overridevirtual

Returns the value of the implicit 'this' object.

Reimplemented from clang::CXXInstanceCall.

Definition at line 897 of file CallEvent.cpp.

References clang::ento::CallEvent::Data.

◆ getKind()

Kind clang::CXXDestructorCall::getKind ( ) const
inlineoverride

Definition at line 850 of file CallEvent.h.

References clang::ento::CE_CXXDestructor.

◆ getNumArgs()

unsigned clang::CXXDestructorCall::getNumArgs ( ) const
inlineoverride

Definition at line 838 of file CallEvent.h.

◆ getRuntimeDefinition()

RuntimeDefinition CXXDestructorCall::getRuntimeDefinition ( ) const
override

◆ getSourceRange()

SourceRange clang::CXXDestructorCall::getSourceRange ( ) const
inlineoverride

Definition at line 837 of file CallEvent.h.

◆ isBaseDestructor()

bool clang::CXXDestructorCall::isBaseDestructor ( ) const
inline

Returns true if this is a call to a base class destructor.

Definition at line 846 of file CallEvent.h.

Friends And Related Function Documentation

◆ CallEventManager

friend class CallEventManager
friend

Definition at line 812 of file CallEvent.h.


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