diff options
Diffstat (limited to 'include/clang/ARCMigrate/ARCMT.h')
-rw-r--r-- | include/clang/ARCMigrate/ARCMT.h | 36 |
1 files changed, 21 insertions, 15 deletions
diff --git a/include/clang/ARCMigrate/ARCMT.h b/include/clang/ARCMigrate/ARCMT.h index ad4f23c..7408186 100644 --- a/include/clang/ARCMigrate/ARCMT.h +++ b/include/clang/ARCMigrate/ARCMT.h @@ -17,6 +17,7 @@ namespace clang { class ASTContext; class DiagnosticConsumer; + class PCHContainerOperations; namespace arcmt { class MigrationPass; @@ -37,19 +38,22 @@ namespace arcmt { /// the pre-migration ARC diagnostics. /// /// \returns false if no error is produced, true otherwise. -bool checkForManualIssues(CompilerInvocation &CI, - const FrontendInputFile &Input, - DiagnosticConsumer *DiagClient, - bool emitPremigrationARCErrors = false, - StringRef plistOut = StringRef()); +bool +checkForManualIssues(CompilerInvocation &CI, const FrontendInputFile &Input, + std::shared_ptr<PCHContainerOperations> PCHContainerOps, + DiagnosticConsumer *DiagClient, + bool emitPremigrationARCErrors = false, + StringRef plistOut = StringRef()); /// \brief Works similar to checkForManualIssues but instead of checking, it /// applies automatic modifications to source files to conform to ARC. /// /// \returns false if no error is produced, true otherwise. -bool applyTransformations(CompilerInvocation &origCI, - const FrontendInputFile &Input, - DiagnosticConsumer *DiagClient); +bool +applyTransformations(CompilerInvocation &origCI, + const FrontendInputFile &Input, + std::shared_ptr<PCHContainerOperations> PCHContainerOps, + DiagnosticConsumer *DiagClient); /// \brief Applies automatic modifications and produces temporary files /// and metadata into the \p outputDir path. @@ -62,12 +66,11 @@ bool applyTransformations(CompilerInvocation &origCI, /// the pre-migration ARC diagnostics. /// /// \returns false if no error is produced, true otherwise. -bool migrateWithTemporaryFiles(CompilerInvocation &origCI, - const FrontendInputFile &Input, - DiagnosticConsumer *DiagClient, - StringRef outputDir, - bool emitPremigrationARCErrors, - StringRef plistOut); +bool migrateWithTemporaryFiles( + CompilerInvocation &origCI, const FrontendInputFile &Input, + std::shared_ptr<PCHContainerOperations> PCHContainerOps, + DiagnosticConsumer *DiagClient, StringRef outputDir, + bool emitPremigrationARCErrors, StringRef plistOut); /// \brief Get the set of file remappings from the \p outputDir path that /// migrateWithTemporaryFiles produced. @@ -93,13 +96,16 @@ std::vector<TransformFn> getAllTransformations(LangOptions::GCMode OrigGCMode, class MigrationProcess { CompilerInvocation OrigCI; + std::shared_ptr<PCHContainerOperations> PCHContainerOps; DiagnosticConsumer *DiagClient; FileRemapper Remapper; public: bool HadARCErrors; - MigrationProcess(const CompilerInvocation &CI, DiagnosticConsumer *diagClient, + MigrationProcess(const CompilerInvocation &CI, + std::shared_ptr<PCHContainerOperations> PCHContainerOps, + DiagnosticConsumer *diagClient, StringRef outputDir = StringRef()); class RewriteListener { |