[patch] Make std::vector<bool> meet C++11 allocator requirements.
Jonathan Wakely
jwakely@redhat.com
Fri Oct 31 20:49:00 GMT 2014
There's no better time to fix evil vector<bool> than Halloween.
All allocator operations must go through allocator_traits and
_Bit_type* must be replaced with the allocator's pointer type.
Rather than rewriting all the iterators and base classes to use
_Bit_pointer everywhere I only changed _M_end_of_storage and added
_M_end_addr() to convert it from _Bit_pointer to _Bit_type*, which
optimizes to nothing for the usual case where they're the same type.
Tested x86_64-linux, committed to trunk.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.txt
Type: text/x-patch
Size: 32624 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20141031/7a29eecf/attachment.bin>
More information about the Libstdc++
mailing list