]> git.ipfire.org Git - thirdparty/gcc.git/commit
libstdc++: Add missing parts of LWG 3480 for directory iterators [PR117560]
authorJonathan Wakely <jwakely@redhat.com>
Thu, 14 Nov 2024 01:14:44 +0000 (01:14 +0000)
committerJonathan Wakely <jwakely@redhat.com>
Wed, 16 Apr 2025 17:43:16 +0000 (18:43 +0100)
commit5f3811fd50113571127b849325ab8f6c674158af
tree06ac93059dece4f9b4e720d0726c3295176444e3
parent4889daddae1062528bd8d3578635af20cc31fcfc
libstdc++: Add missing parts of LWG 3480 for directory iterators [PR117560]

It looks like I only read half the resolution of LWG 3480 and decided we
already supported it. As well as making the non-member overloads of end
take their parameters by value, we need some specializations of the
enable_borrowed_range and enable_view variable templates.

libstdc++-v3/ChangeLog:

PR libstdc++/117560
* include/bits/fs_dir.h (enable_borrowed_range, enable_view):
Define specializations for directory iterators, as per LWG 3480.
* testsuite/27_io/filesystem/iterators/lwg3480.cc: New test.

(cherry picked from commit eec6e8923586b9a54e37f32cef112d26d86e8f01)
libstdc++-v3/include/bits/fs_dir.h
libstdc++-v3/testsuite/27_io/filesystem/iterators/lwg3480.cc [new file with mode: 0644]