This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: Remove unordered containers iterators default initialization
- From: Christopher Jefferson <chris at bubblescope dot net>
- To: François Dumont <frs dot dumont at gmail dot com>
- Cc: "libstdc++ at gcc dot gnu dot org" <libstdc++ at gcc dot gnu dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 25 Nov 2013 23:09:29 +0000
- Subject: Re: Remove unordered containers iterators default initialization
- Authentication-results: sourceware.org; auth=none
- References: <5293BAF5 dot 7070709 at gmail dot com>
On 25 November 2013 21:02, François Dumont <frs.dumont@gmail.com> wrote:
>
> Hi
>
> Following N3644 discussion thread here is a patch proposal to remove default zero-initialization of unordered containers iterator. I also took the time to remove default zero-init of nodes _M_nxt pointer.
>
> 2013-11-25 François Dumont <fdumont@gcc.gnu.org>
>
> * include/bits/hashtable_policy.h (_Hash_node_base): Default
> default constructor.
> (_Node_iterator): Likewise.
> (_Node_const_iterator): Likewise.
> * include/bits/hashtable.h: Adapt.
>
> Tested under Linux x86_64.
>
> Ok to commit ?
>
I just want to check exactly what is going on here, please correct me if I
am wrong.
Before N3644 there was (I believe) no guarantee we either default or value
constructing iterators lead to a default state.
Therefore, we were previously providing more functionality than the
standard required, which you are now removing. Are we sure we want to
remove that extra functionality?
Chris