clang 22.0.0git
CheckObjCDealloc.cpp File Reference

Go to the source code of this file.

Enumerations

enum class  ReleaseRequirement { MustRelease , MustNotReleaseDirectly , Unknown }
 Indicates whether an instance variable is required to be released in -dealloc. More...

Functions

static bool isSynthesizedRetainableProperty (const ObjCPropertyImplDecl *I, const ObjCIvarDecl **ID, const ObjCPropertyDecl **PD)
 Returns true if the property implementation is synthesized and the type of the property is retainable.

Enumeration Type Documentation

◆ ReleaseRequirement

enum class ReleaseRequirement
strong

Indicates whether an instance variable is required to be released in -dealloc.

Enumerator
MustRelease 

The instance variable must be released, either by calling -release on it directly or by nilling it out with a property setter.

MustNotReleaseDirectly 

The instance variable must not be directly released with -release.

Unknown 

The requirement for the instance variable could not be determined.

Definition at line 55 of file CheckObjCDealloc.cpp.

Function Documentation

◆ isSynthesizedRetainableProperty()

bool isSynthesizedRetainableProperty ( const ObjCPropertyImplDecl * I,
const ObjCIvarDecl ** ID,
const ObjCPropertyDecl ** PD )
static

Returns true if the property implementation is synthesized and the type of the property is retainable.

Definition at line 69 of file CheckObjCDealloc.cpp.

References clang::ObjCPropertyImplDecl::getPropertyDecl(), clang::ObjCPropertyImplDecl::getPropertyImplementation(), clang::ObjCPropertyImplDecl::getPropertyIvarDecl(), clang::ObjCPropertyImplDecl::Synthesize, and clang::T.