From: Mehdi Amini Date: Thu, 14 Apr 2016 05:37:41 +0000 (+0000) Subject: Make sure the LLVMContext outlive the CompilerInstance X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=158ca04808583df0672f4a9b980b39334eb11617;p=clang Make sure the LLVMContext outlive the CompilerInstance From: Mehdi Amini git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@266277 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/unittests/CodeGen/BufferSourceTest.cpp b/unittests/CodeGen/BufferSourceTest.cpp index 56aafcee35..1934e66138 100644 --- a/unittests/CodeGen/BufferSourceTest.cpp +++ b/unittests/CodeGen/BufferSourceTest.cpp @@ -39,8 +39,8 @@ const char TestProgram[] = "EmitCXXGlobalInitFunc test; "; TEST(BufferSourceTest, EmitCXXGlobalInitFunc) { - CompilerInstance compiler; LLVMContext Context; + CompilerInstance compiler; compiler.createDiagnostics(); compiler.getLangOpts().CPlusPlus = 1;