#include "Transforms.h"
#include "Internals.h"
#include "clang/ARCMigrate/ARCMT.h"
#include "clang/AST/ASTContext.h"
#include "clang/AST/RecursiveASTVisitor.h"
#include "clang/Analysis/DomainSpecific/CocoaConventions.h"
#include "clang/Basic/SourceManager.h"
#include "clang/Basic/TargetInfo.h"
#include "clang/Lex/Lexer.h"
#include "clang/Lex/Preprocessor.h"
#include "clang/Sema/Sema.h"
#include "clang/Sema/SemaObjC.h"
usingnamespaceclang;
usingnamespacearcmt;
usingnamespacetrans;
ASTTraverser::~ASTTraverser() { … }
bool MigrationPass::CFBridgingFunctionsDefined() { … }
bool trans::canApplyWeak(ASTContext &Ctx, QualType type,
bool AllowOnUnknownClass) { … }
bool trans::isPlusOneAssign(const BinaryOperator *E) { … }
bool trans::isPlusOne(const Expr *E) { … }
SourceLocation trans::findLocationAfterSemi(SourceLocation loc,
ASTContext &Ctx, bool IsDecl) { … }
SourceLocation trans::findSemiAfterLocation(SourceLocation loc,
ASTContext &Ctx,
bool IsDecl) { … }
bool trans::hasSideEffects(Expr *E, ASTContext &Ctx) { … }
bool trans::isGlobalVar(Expr *E) { … }
StringRef trans::getNilString(MigrationPass &Pass) { … }
namespace {
class ReferenceClear : public RecursiveASTVisitor<ReferenceClear> { … };
class ReferenceCollector : public RecursiveASTVisitor<ReferenceCollector> { … };
class RemovablesCollector : public RecursiveASTVisitor<RemovablesCollector> { … };
}
void trans::clearRefsIn(Stmt *S, ExprSet &refs) { … }
void trans::collectRefs(ValueDecl *D, Stmt *S, ExprSet &refs) { … }
void trans::collectRemovables(Stmt *S, ExprSet &exprs) { … }
namespace {
class ASTTransform : public RecursiveASTVisitor<ASTTransform> { … };
}
MigrationContext::~MigrationContext() { … }
bool MigrationContext::isGCOwnedNonObjC(QualType T) { … }
bool MigrationContext::rewritePropertyAttribute(StringRef fromAttr,
StringRef toAttr,
SourceLocation atLoc) { … }
bool MigrationContext::addPropertyAttribute(StringRef attr,
SourceLocation atLoc) { … }
void MigrationContext::traverse(TranslationUnitDecl *TU) { … }
static void GCRewriteFinalize(MigrationPass &pass) { … }
static void traverseAST(MigrationPass &pass) { … }
static void independentTransforms(MigrationPass &pass) { … }
std::vector<TransformFn> arcmt::getAllTransformations(
LangOptions::GCMode OrigGCMode,
bool NoFinalizeRemoval) { … }