From d87f8d76e0633141712c32bc5266903e0a7715cd Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Wed, 27 Aug 2014 20:03:29 +0000 Subject: Update for LLVM api change. llvm-svn: 216585 --- clang/lib/Frontend/CompilerInstance.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'clang/lib/Frontend/CompilerInstance.cpp') diff --git a/clang/lib/Frontend/CompilerInstance.cpp b/clang/lib/Frontend/CompilerInstance.cpp index a4365588905..a535afdc056 100644 --- a/clang/lib/Frontend/CompilerInstance.cpp +++ b/clang/lib/Frontend/CompilerInstance.cpp @@ -947,11 +947,11 @@ static bool compileModuleImpl(CompilerInstance &ImportingInstance, FrontendOpts.Inputs.push_back( FrontendInputFile("__inferred_module.map", IK)); - llvm::MemoryBuffer *ModuleMapBuffer = + std::unique_ptr ModuleMapBuffer = llvm::MemoryBuffer::getMemBuffer(InferredModuleMapContent); ModuleMapFile = Instance.getFileManager().getVirtualFile( "__inferred_module.map", InferredModuleMapContent.size(), 0); - SourceMgr.overrideFileContents(ModuleMapFile, ModuleMapBuffer); + SourceMgr.overrideFileContents(ModuleMapFile, ModuleMapBuffer.release()); } // Construct a module-generating action. Passing through the module map is -- cgit v1.2.3