clang 20.0.0git
Public Member Functions | Friends | List of all members
clang::ento::RetainSummary Class Reference

Summary for a function with respect to ownership changes. More...

#include "clang/Analysis/RetainSummaryManager.h"

Public Member Functions

 RetainSummary (ArgEffects A, RetEffect R, ArgEffect defaultEff, ArgEffect ReceiverEff, ArgEffect ThisEff)
 
ArgEffect getArg (unsigned idx) const
 getArg - Return the argument effect on the argument specified by idx (starting from 0).
 
void addArg (ArgEffects::Factory &af, unsigned idx, ArgEffect e)
 
void setDefaultArgEffect (ArgEffect E)
 setDefaultArgEffect - Set the default argument effect.
 
RetEffect getRetEffect () const
 getRetEffect - Returns the effect on the return value of the call.
 
void setRetEffect (RetEffect E)
 setRetEffect - Set the effect of the return value of the call.
 
void setReceiverEffect (ArgEffect e)
 Sets the effect on the receiver of the message.
 
ArgEffect getReceiverEffect () const
 getReceiverEffect - Returns the effect on the receiver of the call.
 
ArgEffect getThisEffect () const
 
ArgEffect getDefaultEffect () const
 
void setThisEffect (ArgEffect e)
 Set the effect of the method on "this".
 
bool isNoop () const
 
bool operator== (const RetainSummary &Other) const
 Test if two retain summaries are identical.
 
void Profile (llvm::FoldingSetNodeID &ID) const
 Profile this summary for inclusion in a FoldingSet.
 
bool isSimple () const
 A retain summary is simple if it has no ArgEffects other than the default.
 
ArgEffects getArgEffects () const
 

Friends

class RetainSummaryManager
 

Detailed Description

Summary for a function with respect to ownership changes.

Definition at line 283 of file RetainSummaryManager.h.

Constructor & Destructor Documentation

◆ RetainSummary()

clang::ento::RetainSummary::RetainSummary ( ArgEffects  A,
RetEffect  R,
ArgEffect  defaultEff,
ArgEffect  ReceiverEff,
ArgEffect  ThisEff 
)
inline

Definition at line 305 of file RetainSummaryManager.h.

Member Function Documentation

◆ addArg()

void clang::ento::RetainSummary::addArg ( ArgEffects::Factory &  af,
unsigned  idx,
ArgEffect  e 
)
inline

Definition at line 322 of file RetainSummaryManager.h.

◆ getArg()

ArgEffect clang::ento::RetainSummary::getArg ( unsigned  idx) const
inline

getArg - Return the argument effect on the argument specified by idx (starting from 0).

Definition at line 315 of file RetainSummaryManager.h.

Referenced by clang::ento::retaincountchecker::RetainCountChecker::checkSummary(), clang::ento::retaincountchecker::RetainCountChecker::processSummaryOfInlined(), and updateOutParameters().

◆ getArgEffects()

ArgEffects clang::ento::RetainSummary::getArgEffects ( ) const
inline

◆ getDefaultEffect()

ArgEffect clang::ento::RetainSummary::getDefaultEffect ( ) const
inline

Definition at line 349 of file RetainSummaryManager.h.

◆ getReceiverEffect()

ArgEffect clang::ento::RetainSummary::getReceiverEffect ( ) const
inline

getReceiverEffect - Returns the effect on the receiver of the call.

This is only meaningful if the summary applies to an ObjCMessageExpr*.

Definition at line 343 of file RetainSummaryManager.h.

Referenced by clang::ento::retaincountchecker::RetainCountChecker::checkSummary(), and clang::ento::retaincountchecker::RetainCountChecker::processSummaryOfInlined().

◆ getRetEffect()

RetEffect clang::ento::RetainSummary::getRetEffect ( ) const
inline

getRetEffect - Returns the effect on the return value of the call.

Definition at line 332 of file RetainSummaryManager.h.

Referenced by clang::ento::retaincountchecker::RetainCountChecker::checkSummary(), and clang::ento::retaincountchecker::RetainCountChecker::processSummaryOfInlined().

◆ getThisEffect()

ArgEffect clang::ento::RetainSummary::getThisEffect ( ) const
inline
Returns
the effect on the "this" receiver of the method call. This is only meaningful if the summary applies to CXXMethodDecl*.

Definition at line 347 of file RetainSummaryManager.h.

Referenced by clang::ento::retaincountchecker::RetainCountChecker::checkSummary().

◆ isNoop()

bool clang::ento::RetainSummary::isNoop ( ) const
inline

◆ isSimple()

bool clang::ento::RetainSummary::isSimple ( ) const
inline

A retain summary is simple if it has no ArgEffects other than the default.

Definition at line 378 of file RetainSummaryManager.h.

◆ operator==()

bool clang::ento::RetainSummary::operator== ( const RetainSummary Other) const
inline

Test if two retain summaries are identical.

Note that merely equivalent summaries are not necessarily identical (for example, if an explicit argument effect matches the default effect).

Definition at line 363 of file RetainSummaryManager.h.

References clang::Other.

◆ Profile()

void clang::ento::RetainSummary::Profile ( llvm::FoldingSetNodeID &  ID) const
inline

Profile this summary for inclusion in a FoldingSet.

Definition at line 369 of file RetainSummaryManager.h.

◆ setDefaultArgEffect()

void clang::ento::RetainSummary::setDefaultArgEffect ( ArgEffect  E)
inline

setDefaultArgEffect - Set the default argument effect.

Definition at line 327 of file RetainSummaryManager.h.

References E.

◆ setReceiverEffect()

void clang::ento::RetainSummary::setReceiverEffect ( ArgEffect  e)
inline

Sets the effect on the receiver of the message.

Definition at line 339 of file RetainSummaryManager.h.

◆ setRetEffect()

void clang::ento::RetainSummary::setRetEffect ( RetEffect  E)
inline

setRetEffect - Set the effect of the return value of the call.

Definition at line 335 of file RetainSummaryManager.h.

References E.

◆ setThisEffect()

void clang::ento::RetainSummary::setThisEffect ( ArgEffect  e)
inline

Set the effect of the method on "this".

Definition at line 352 of file RetainSummaryManager.h.

Friends And Related Function Documentation

◆ RetainSummaryManager

friend class RetainSummaryManager
friend

Definition at line 387 of file RetainSummaryManager.h.


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