Skip to content

Commit

Permalink
Remove redundant macro check in nostd::shared_ptr (#1939)
Browse files Browse the repository at this point in the history
  • Loading branch information
ThomsonTan authored Jan 27, 2023
1 parent 52309dd commit 7e7184d
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions api/include/opentelemetry/nostd/shared_ptr.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,13 +103,11 @@ class shared_ptr
new (buffer_.data) shared_ptr_wrapper{std::move(ptr_)};
}

# ifndef HAVE_CPP_STDLIB
shared_ptr(std::unique_ptr<T> &&other) noexcept
{
std::shared_ptr<T> ptr_(other.release());
new (buffer_.data) shared_ptr_wrapper{std::move(ptr_)};
}
# endif

~shared_ptr() { wrapper().~shared_ptr_wrapper(); }

Expand Down

0 comments on commit 7e7184d

Please sign in to comment.