Skip to content
Commit 4b9ae52a authored by David Blaikie's avatar David Blaikie
Browse files

Correct the ownership passing semantics of object::createBinary and make them...

Correct the ownership passing semantics of object::createBinary and make them explicit in the type system.

createBinary documented that it destroyed the parameter in error cases,
though by observation it does not. By passing the unique_ptr by value
rather than lvalue reference, callers are now explicit about passing
ownership and the function implements the documented contract. Remove
the explicit documentation, since now the behavior cannot be anything
other than what was documented, so it's redundant.

Also drops a unique_ptr::release in llvm-nm that was always run on a
null unique_ptr anyway.

llvm-svn: 213557
parent dc01ca18
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment