aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/src
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2025-03-11 15:47:21 +0000
committerJonathan Wakely <redi@gcc.gnu.org>2025-03-12 10:12:36 +0000
commit04815ae0a2b27895411506813db3a8b460be1d6d (patch)
tree218ac246ad52f901a8f0c2b30e58aa7ca0c14f14 /libstdc++-v3/src
parenta21847acb8bb1101c15deef1b55d929e65c9ada4 (diff)
downloadgcc-04815ae0a2b27895411506813db3a8b460be1d6d.zip
gcc-04815ae0a2b27895411506813db3a8b460be1d6d.tar.gz
gcc-04815ae0a2b27895411506813db3a8b460be1d6d.tar.bz2
libstdc++: Make range adaptor __has_arrow helper use a const type
LWG 4112 (approved in Wrocław, November 2024) changes the has-arrow helper to require operator-> to be valid on a const-qualified lvalue. This affects the constraints for filter_view::_Iterator::operator-> and join_view::_Iterator::operator-> so that they can only be used if the underlying iterator supports operator-> on const. The change also adds semantic (i.e. not checkable and not enforced) requirements that operator-> must have the same semantics whether called on a const or non-const value, and on an lvalue or rvalue (due to the implicit expression variation rules in [concepts.equality]). libstdc++-v3/ChangeLog: * include/bits/ranges_util.h (ranges::_detail::__has_arrow): Require operator->() to be valid on const-qualified type, as per LWG 4112. * testsuite/std/ranges/adaptors/lwg4112.cc: New test. Reviewed-by: Tomasz Kamiński <tkaminsk@redhat.com>
Diffstat (limited to 'libstdc++-v3/src')
0 files changed, 0 insertions, 0 deletions