aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Object/Archive.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Object/Archive.cpp')
-rw-r--r--lib/Object/Archive.cpp21
1 files changed, 2 insertions, 19 deletions
diff --git a/lib/Object/Archive.cpp b/lib/Object/Archive.cpp
index 999bf28..304ca47 100644
--- a/lib/Object/Archive.cpp
+++ b/lib/Object/Archive.cpp
@@ -13,7 +13,6 @@
#include "llvm/Object/Archive.h"
#include "llvm/ADT/APInt.h"
-#include "llvm/ADT/OwningPtr.h"
#include "llvm/ADT/SmallString.h"
#include "llvm/ADT/Twine.h"
#include "llvm/Support/Endian.h"
@@ -111,7 +110,7 @@ Archive::Child Archive::Child::getNext() const {
// Check to see if this is past the end of the archive.
if (NextLoc >= Parent->Data->getBufferEnd())
- return Child(Parent, NULL);
+ return Child(Parent, nullptr);
return Child(Parent, NextLoc);
}
@@ -183,14 +182,6 @@ error_code Archive::Child::getMemoryBuffer(std::unique_ptr<MemoryBuffer> &Result
return error_code::success();
}
-error_code Archive::Child::getMemoryBuffer(OwningPtr<MemoryBuffer> &Result,
- bool FullPath) const {
- std::unique_ptr<MemoryBuffer> MB;
- error_code ec = getMemoryBuffer(MB, FullPath);
- Result = std::move(MB);
- return ec;
-}
-
error_code Archive::Child::getAsBinary(std::unique_ptr<Binary> &Result,
LLVMContext *Context) const {
std::unique_ptr<Binary> ret;
@@ -204,14 +195,6 @@ error_code Archive::Child::getAsBinary(std::unique_ptr<Binary> &Result,
return object_error::success;
}
-error_code Archive::Child::getAsBinary(OwningPtr<Binary> &Result,
- LLVMContext *Context) const {
- std::unique_ptr<Binary> B;
- error_code ec = getAsBinary(B, Context);
- Result = std::move(B);
- return ec;
-}
-
ErrorOr<Archive*> Archive::create(MemoryBuffer *Source) {
error_code EC;
std::unique_ptr<Archive> Ret(new Archive(Source, EC));
@@ -349,7 +332,7 @@ Archive::child_iterator Archive::child_begin(bool SkipInternal) const {
}
Archive::child_iterator Archive::child_end() const {
- return Child(this, NULL);
+ return Child(this, nullptr);
}
error_code Archive::Symbol::getName(StringRef &Result) const {