[PATCH] Fix _GLIBCXX_DEBUG container allocator aware move constructors

François Dumont frs.dumont@gmail.com
Fri Mar 26 20:41:39 GMT 2021


I review the allocator aware move constructors of _GLIBCXX_DEBUG containers.

I think the recently added __gnu_debug basic_string one is also missing 
the rvalue reference, no ?

     libstdc++: _GLIBCXX_DEBUG Fix allocator aware move constructor

     Fix several allocator aware move construtor in _GLIBCXX_DEBUG
     containers.

     libstdc++-v3/ChangeLog:
             * include/debug/forward_list
             (forward_list(forward_list&&, const allocator_type&)): Add 
noexcept qualification.
             * include/debug/list (list(list&&, const allocator_type&)): 
Likewise and add
             call to safe container allocator aware move constructor.
             * include/debug/string (basic_string(basic_string&&, const 
_Allocator&)):
             Check base type allocator aware more constructor.
             * include/debug/vector (vector(vector&&, const 
allocator_type&)):
             Fix noexcept qualification.
             * 
testsuite/23_containers/forward_list/cons/noexcept_move_construct.cc:
             Add allocator aware move constructor noexceot qualification 
check.
             * 
testsuite/23_containers/list/cons/noexcept_move_construct.cc: Likewise.

Tested under linux x86_64.

Ok to commit ?

François

-------------- next part --------------
A non-text attachment was scrubbed...
Name: debug_noexcept-cons.patch
Type: text/x-patch
Size: 4034 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20210326/7d5f251e/attachment.bin>


More information about the Gcc-patches mailing list