summaryrefslogtreecommitdiff
path: root/tools/arcmt-test
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2012-03-06 20:06:33 +0000
committerTed Kremenek <kremenek@apple.com>2012-03-06 20:06:33 +0000
commit30660a898545416f0fea2d717f16f75640001e38 (patch)
treea8408d8c12d992b4110fca1bfe78f337b48f5d11 /tools/arcmt-test
parent2a253960f0312c9759965a1defb9326d6b2764a4 (diff)
downloadclang-30660a898545416f0fea2d717f16f75640001e38.tar.gz
clang-30660a898545416f0fea2d717f16f75640001e38.tar.bz2
clang-30660a898545416f0fea2d717f16f75640001e38.tar.xz
Add new code migrator support for migrating existing Objective-C code to use
the new Objective-C NSArray/NSDictionary/NSNumber literal syntax. This introduces a new library, libEdit, which provides a new way to support migration of code that improves on the original ARC migrator. We now believe that most of its functionality can be refactored into the existing libraries, and thus this new library may shortly disappear. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152141 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/arcmt-test')
-rw-r--r--tools/arcmt-test/CMakeLists.txt1
-rw-r--r--tools/arcmt-test/Makefile2
-rw-r--r--tools/arcmt-test/arcmt-test.cpp5
3 files changed, 4 insertions, 4 deletions
diff --git a/tools/arcmt-test/CMakeLists.txt b/tools/arcmt-test/CMakeLists.txt
index 9227f8ee63..a0029b416f 100644
--- a/tools/arcmt-test/CMakeLists.txt
+++ b/tools/arcmt-test/CMakeLists.txt
@@ -1,5 +1,6 @@
set(LLVM_USED_LIBS
clangARCMigrate
+ clangEdit
clangRewrite
)
diff --git a/tools/arcmt-test/Makefile b/tools/arcmt-test/Makefile
index c143e27f33..f5ca81a6d1 100644
--- a/tools/arcmt-test/Makefile
+++ b/tools/arcmt-test/Makefile
@@ -19,6 +19,6 @@ NO_INSTALL = 1
LINK_COMPONENTS := support mc
USEDLIBS = clangIndex.a clangARCMigrate.a clangRewrite.a \
clangFrontend.a clangDriver.a clangSerialization.a clangParse.a \
- clangSema.a clangAnalysis.a clangAST.a clangLex.a clangBasic.a
+ clangSema.a clangEdit.a clangAnalysis.a clangAST.a clangLex.a clangBasic.a
include $(CLANG_LEVEL)/Makefile
diff --git a/tools/arcmt-test/arcmt-test.cpp b/tools/arcmt-test/arcmt-test.cpp
index 881a058c2c..2dc8034e32 100644
--- a/tools/arcmt-test/arcmt-test.cpp
+++ b/tools/arcmt-test/arcmt-test.cpp
@@ -135,9 +135,8 @@ static bool checkForMigration(StringRef resourcesPath,
}
static void printResult(FileRemapper &remapper, raw_ostream &OS) {
- CompilerInvocation CI;
- remapper.applyMappings(CI);
- PreprocessorOptions &PPOpts = CI.getPreprocessorOpts();
+ PreprocessorOptions PPOpts;
+ remapper.applyMappings(PPOpts);
// The changed files will be in memory buffers, print them.
for (unsigned i = 0, e = PPOpts.RemappedFileBuffers.size(); i != e; ++i) {
const llvm::MemoryBuffer *mem = PPOpts.RemappedFileBuffers[i].second;