clang 20.0.0git
|
Classes | |
class | ASTTraverser |
class | BlockObjCVariableTraverser |
class | BodyContext |
class | BodyTransform |
class | GCAttrsTraverser |
class | GCCollectableCallsTraverser |
class | MigrationContext |
class | ObjCImplementationContext |
class | PropertyRewriteTraverser |
class | ProtectedScopeTraverser |
Typedefs | |
typedef llvm::DenseSet< Expr * > | ExprSet |
typedef llvm::DenseSet<Expr *> clang::arcmt::trans::ExprSet |
Definition at line 205 of file Transforms.h.
bool clang::arcmt::trans::canApplyWeak | ( | ASTContext & | Ctx, |
QualType | type, | ||
bool | AllowOnUnknownClass = false |
||
) |
Determine whether we can add weak to the given type.
Definition at line 39 of file Transforms.cpp.
References clang::Class, clang::Type::getAs(), clang::ASTContext::getLangOpts(), clang::Type::getPointeeType(), clang::ASTContext::getTargetInfo(), clang::TargetInfo::getTriple(), clang::T, and clang::ast_matchers::type.
Referenced by checkAllAtProps(), checkWeakGCAttrs(), and clang::arcmt::trans::BlockObjCVariableTraverser::traverseBody().
void clang::arcmt::trans::checkAPIUses | ( | MigrationPass & | pass | ) |
Definition at line 105 of file TransAPIUses.cpp.
References clang::arcmt::MigrationPass::Ctx, and clang::ASTContext::getTranslationUnitDecl().
Referenced by independentTransforms().
void clang::arcmt::trans::clearRefsIn | ( | iterator | begin, |
iterator | end, | ||
ExprSet & | refs | ||
) |
Definition at line 209 of file Transforms.h.
References clearRefsIn().
Definition at line 300 of file Transforms.cpp.
Referenced by clearRefsIn().
Definition at line 304 of file Transforms.cpp.
References D.
Definition at line 308 of file Transforms.cpp.
SourceLocation clang::arcmt::trans::findLocationAfterSemi | ( | SourceLocation | loc, |
ASTContext & | Ctx, | ||
bool | IsDecl = false |
||
) |
'Loc' is the end of a statement range.
This returns the location immediately after the semicolon following the statement. If no semicolon is found or the location is inside a macro, the returned source location will be invalid.
Definition at line 117 of file Transforms.cpp.
References findSemiAfterLocation(), clang::SourceLocation::getLocWithOffset(), and clang::SourceLocation::isInvalid().
Referenced by rewriteToNSEnumDecl().
SourceLocation clang::arcmt::trans::findSemiAfterLocation | ( | SourceLocation | loc, |
ASTContext & | Ctx, | ||
bool | IsDecl = false |
||
) |
'Loc' is the end of a statement range.
This returns the location of the semicolon following the statement. If no semicolon is found or the location is inside a macro, the returned source location will be invalid.
Definition at line 129 of file Transforms.cpp.
References findSemiAfterLocation(), clang::ASTContext::getLangOpts(), clang::Token::getLocation(), clang::Lexer::getLocForEndOfToken(), clang::ASTContext::getSourceManager(), clang::Lexer::isAtEndOfMacroExpansion(), clang::SourceLocation::isMacroID(), clang::Token::isNot(), clang::Lexer::LexFromRawLexer(), and SM.
Referenced by findLocationAfterSemi(), findSemiAfterLocation(), isEmptyARCMTMacroStatement(), and rewriteToNSEnumDecl().
StringRef clang::arcmt::trans::getNilString | ( | MigrationPass & | Pass | ) |
Returns "nil" or "0" if 'nil' macro is not actually defined.
Definition at line 208 of file Transforms.cpp.
References clang::Preprocessor::isMacroDefined(), clang::Sema::PP, and clang::arcmt::MigrationPass::SemaRef.
bool clang::arcmt::trans::hasSideEffects | ( | Expr * | E, |
ASTContext & | Ctx | ||
) |
Definition at line 167 of file Transforms.cpp.
References E, clang::ObjCMessageExpr::getInstanceReceiver(), clang::ObjCMessageExpr::getMethodFamily(), clang::ObjCMessageExpr::getReceiverKind(), clang::Expr::HasSideEffects(), hasSideEffects(), clang::Expr::IgnoreParenCasts(), clang::ObjCMessageExpr::Instance, clang::OMF_autorelease, clang::OMF_dealloc, clang::OMF_release, clang::OMF_retain, and clang::ObjCMessageExpr::SuperInstance.
Referenced by hasSideEffects().
Definition at line 196 of file Transforms.cpp.
References E, clang::Expr::IgnoreParenCasts(), and isGlobalVar().
Referenced by isGlobalVar().
Definition at line 75 of file Transforms.cpp.
References E, clang::CastExpr::getCastKind(), clang::CastExpr::getSubExpr(), clang::Expr::IgnoreParenCasts(), clang::ento::cocoa::isRefType(), and clang::OMF_retain.
Referenced by isPlusOneAssign().
bool clang::arcmt::trans::isPlusOneAssign | ( | const BinaryOperator * | E | ) |
Definition at line 68 of file Transforms.cpp.
References E, and isPlusOne().
void clang::arcmt::trans::makeAssignARCSafe | ( | MigrationPass & | pass | ) |
Definition at line 74 of file TransARCAssign.cpp.
References clang::arcmt::MigrationPass::Ctx, and clang::ASTContext::getTranslationUnitDecl().
Referenced by independentTransforms().
void clang::arcmt::trans::removeEmptyStatementsAndDeallocFinalize | ( | MigrationPass & | pass | ) |
Definition at line 240 of file TransEmptyStatementsAndDealloc.cpp.
References clang::arcmt::MigrationPass::ARCMTMacroLocs, cleanupDeallocOrFinalize(), clang::arcmt::MigrationPass::Ctx, clang::ASTContext::getTranslationUnitDecl(), clang::arcmt::TransformActions::remove(), and clang::arcmt::MigrationPass::TA.
Referenced by clang::arcmt::getAllTransformations().
void clang::arcmt::trans::removeRetainReleaseDeallocFinalize | ( | MigrationPass & | pass | ) |
Definition at line 456 of file TransRetainReleaseDealloc.cpp.
References clang::arcmt::MigrationPass::Ctx, clang::ASTContext::getTranslationUnitDecl(), and clang::RecursiveASTVisitor< Derived >::TraverseDecl().
Referenced by independentTransforms().
void clang::arcmt::trans::removeZeroOutPropsInDeallocFinalize | ( | MigrationPass & | pass | ) |
Definition at line 221 of file TransZeroOutPropsInDealloc.cpp.
References clang::arcmt::MigrationPass::Ctx, and clang::ASTContext::getTranslationUnitDecl().
Referenced by independentTransforms().
void clang::arcmt::trans::rewriteAutoreleasePool | ( | MigrationPass & | pass | ) |
Definition at line 432 of file TransAutoreleasePool.cpp.
References clang::arcmt::MigrationPass::Ctx, clang::ASTContext::getTranslationUnitDecl(), and clang::RecursiveASTVisitor< Derived >::TraverseDecl().
Referenced by independentTransforms().
void clang::arcmt::trans::rewriteUnbridgedCasts | ( | MigrationPass & | pass | ) |
Definition at line 463 of file TransUnbridgedCasts.cpp.
References clang::arcmt::MigrationPass::Ctx, clang::ASTContext::getTranslationUnitDecl(), and clang::RecursiveASTVisitor< Derived >::TraverseDecl().
Referenced by independentTransforms().
void clang::arcmt::trans::rewriteUnusedInitDelegate | ( | MigrationPass & | pass | ) |
Definition at line 74 of file TransUnusedInitDelegate.cpp.
References clang::arcmt::MigrationPass::Ctx, clang::ASTContext::getTranslationUnitDecl(), and clang::RecursiveASTVisitor< Derived >::TraverseDecl().
Referenced by independentTransforms().