projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
07b21d7
)
Remove unnecessary use of unique_ptr::release() used to construct another unique_ptr.
author
David Blaikie
<dblaikie@gmail.com>
Mon, 21 Jul 2014 16:23:21 +0000
(16:23 +0000)
committer
David Blaikie
<dblaikie@gmail.com>
Mon, 21 Jul 2014 16:23:21 +0000
(16:23 +0000)
llvm-svn: 213556
llvm/lib/Object/Archive.cpp
patch
|
blob
|
history
diff --git
a/llvm/lib/Object/Archive.cpp
b/llvm/lib/Object/Archive.cpp
index 63877913937e84562f426ee9656b57ef0dc9f0a3..3c683408969d5b3ba57f8077bef1bae705210211 100644
(file)
--- a/
llvm/lib/Object/Archive.cpp
+++ b/
llvm/lib/Object/Archive.cpp
@@
-181,8
+181,7
@@
Archive::Child::getAsBinary(LLVMContext *Context) const {
if (std::error_code EC = BuffOrErr.getError())
return EC;
- std::unique_ptr<MemoryBuffer> Buff(BuffOrErr.get().release());
- return createBinary(Buff, Context);
+ return createBinary(*BuffOrErr, Context);
}
ErrorOr<Archive *> Archive::create(std::unique_ptr<MemoryBuffer> Source) {