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

--- Comment #16 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:8b8e5ed6cd0f3cfe7cdf93200e47c069fd101984

commit r15-2651-g8b8e5ed6cd0f3cfe7cdf93200e47c069fd101984
Author: Jonathan Wakely <jwak...@redhat.com>
Date:   Thu Mar 7 16:00:01 2024 +0000

    libstdc++: Constrain std::basic_string default constructor [PR113841]

    This is needed to avoid errors outside the immediate context when
    evaluating is_default_constructible_v<basic_string<C, T, A>> when A is
    not default constructible.

    This change is not sufficient to solve the problem because there are a
    large number of member functions which have a default argument that
    constructs an allocator.

    libstdc++-v3/ChangeLog:

            PR libstdc++/113841
            * include/bits/basic_string.h (basic_string::basic_string()):
            Constrain so that it's only present if the allocator is default
            constructible.
            * include/bits/cow_string.h (basic_string::basic_string()):
            Likewise.
            * testsuite/21_strings/basic_string/cons/113841.cc: New test.

Reply via email to