[Bug libstdc++/122661] Incorrect value category handling in forward_list::assign
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Fri Nov 14 15:59:07 GMT 2025
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122661
--- Comment #5 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-13 branch has been updated by Jonathan Wakely
<redi@gcc.gnu.org>:
https://gcc.gnu.org/g:ec30d56ed6a02cb84e5a153b7e69fc14695772ae
commit r13-9967-gec30d56ed6a02cb84e5a153b7e69fc14695772ae
Author: Jonathan Wakely <jwakely@redhat.com>
Date: Thu Nov 13 09:45:12 2025 +0000
libstdc++: Fix std::forward_list::assign assignable check [PR122661]
The std::is_assignable check should test for assignment to an lvalue,
not an rvalue.
libstdc++-v3/ChangeLog:
PR libstdc++/122661
* include/bits/forward_list.h (forward_list::assign(I, I)): Fix
value category in is_assignable check.
* testsuite/23_containers/forward_list/modifiers/122661.cc:
New test.
(cherry picked from commit 9332dfd4523ddb100668a7c11a144a2bd676da7e)
More information about the Gcc-bugs
mailing list