Handle removal of llvm::make_unique()
This commit is contained in:
@@ -89,7 +89,11 @@ extern "C" void LLVMRustDestroyArchive(LLVMRustArchiveRef RustArchive) {
|
||||
extern "C" LLVMRustArchiveIteratorRef
|
||||
LLVMRustArchiveIteratorNew(LLVMRustArchiveRef RustArchive) {
|
||||
Archive *Archive = RustArchive->getBinary();
|
||||
#if LLVM_VERSION_GE(10, 0)
|
||||
std::unique_ptr<Error> Err = std::make_unique<Error>(Error::success());
|
||||
#else
|
||||
std::unique_ptr<Error> Err = llvm::make_unique<Error>(Error::success());
|
||||
#endif
|
||||
auto Cur = Archive->child_begin(*Err);
|
||||
if (*Err) {
|
||||
LLVMRustSetLastError(toString(std::move(*Err)).c_str());
|
||||
|
||||
Reference in New Issue
Block a user