]> 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>
Mon, 2 Dec 2024 22:41:40 +0000 (22:41 +0000)
commitedbe164af12589002dec6ac5fe92304567b0ab98
tree559a5eb51e4dae83af01ae5a39a655fa66f86fcf
parentea95ef3becfd3d9c12acc5ea9b5aa98fcf8f65d7
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]