This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libstdc++/55123] [C++11] Construction of shared_ptr<const T> from unique_ptr<const T> fails


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55123

--- Comment #6 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-10-29 20:32:41 UTC ---
I've previously considered removing the address(const_reference) overload when
is_same<reference,const_reference>, but doing so would not help most code (e.g.
std::vector) work with user-defined allocators that haven't made the same
(not-required-by-the-standard) change.  That wouldn't be a problem for this
specific bug, as shared_ptr explicitly uses std::allocator in the relevant
code, but I'd rather just use allocator<void> instead of allocator<_Tp> anyway.

Feel free to open an issue (either here or the LWG) suggesting a change to
std::allocator ... but I'm juggling too many other things to do that change
without a PR or DR to force me to do it :)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]