]> granicus.if.org Git - clang/commitdiff
Switch clang to use its own LLVMContext (not the global one).
authorDaniel Dunbar <daniel@zuster.org>
Tue, 16 Feb 2010 01:54:33 +0000 (01:54 +0000)
committerDaniel Dunbar <daniel@zuster.org>
Tue, 16 Feb 2010 01:54:33 +0000 (01:54 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@96313 91177308-0d34-0410-b5e6-96231b3b80d8

tools/driver/cc1_main.cpp

index 345132ee7d38399f36075bccf9158e0dc16ef767..30d2a21c93abdf94fd7e9b4595aafa54ac8ca127 100644 (file)
@@ -195,7 +195,7 @@ static int cc1_test(Diagnostic &Diags,
 
 int cc1_main(const char **ArgBegin, const char **ArgEnd,
              const char *Argv0, void *MainAddr) {
-  CompilerInstance Clang(&llvm::getGlobalContext(), false);
+  CompilerInstance Clang(new llvm::LLVMContext, true);
 
   // Run clang -cc1 test.
   if (ArgBegin != ArgEnd && llvm::StringRef(ArgBegin[0]) == "-cc1test") {