llvm::make_unique is gone from LLVM trunk

(but when targeting older versions of LLVM/Clang, COMPILER_PLUGINS_CXX can still
specify -std=c++11)

Change-Id: I1b91f2817516d015bc12b6a3faf1874ab938a3ae
Reviewed-on: https://gerrit.libreoffice.org/77866
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
This commit is contained in:
Stephan Bergmann
2019-08-21 09:01:12 +02:00
parent d053d573d8
commit 8b30e6f034

View File

@@ -11,6 +11,7 @@
#include <memory>
#include <system_error>
#include <utility>
#include "plugin.hxx"
#include "pluginhandler.hxx"
@@ -385,7 +386,11 @@ void PluginHandler::HandleTranslationUnit( ASTContext& context )
std::unique_ptr<ASTConsumer> LibreOfficeAction::CreateASTConsumer( CompilerInstance& Compiler, StringRef )
{
#if __cplusplus >= 201402L
return std::make_unique<PluginHandler>( Compiler, _args );
#else
return llvm::make_unique<PluginHandler>( Compiler, _args );
#endif
}
bool LibreOfficeAction::ParseArgs( const CompilerInstance&, const std::vector< std::string >& args )