https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115098

--- Comment #6 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jonathan Wakely <r...@gcc.gnu.org>:

https://gcc.gnu.org/g:b25b101bc380004b82e25d2b1ef306856c75d864

commit r15-3124-gb25b101bc380004b82e25d2b1ef306856c75d864
Author: Jonathan Wakely <jwak...@redhat.com>
Date:   Wed Aug 21 21:19:46 2024 +0100

    libstdc++: Make std::vector<bool>::reference constructor private [PR115098]

    The standard says this constructor should be private.  LWG 4141 proposes
    to remove it entirely. We still need it, but it doesn't need to be
    public.

    For std::bitset the default constructor is already private (and never
    even defined) but there's a non-standard constructor that's public, but
    doesn't need to be.

    libstdc++-v3/ChangeLog:

            PR libstdc++/115098
            * include/bits/stl_bvector.h (_Bit_reference): Make default
            constructor private. Declare vector and bit iterators as
            friends.
            * include/std/bitset (bitset::reference): Make constructor and
            data members private.
            * testsuite/20_util/bitset/115098.cc: New test.
            * testsuite/23_containers/vector/bool/115098.cc: New test.

Reply via email to