Section: 31.12.11 [fs.class.directory.iterator], 31.12.12 [fs.class.rec.dir.itr] Status: C++17 Submitter: Eric Fiselier Opened: 2016-05-28 Last modified: 2021-06-06 18:38:24 UTC
View all other issues in [fs.class.directory.iterator].
View all issues with C++17 status.
Constructing or performing an increment on directory iterator types can result in an error. Currently there is implementation divergence regarding the value of the iterator after an error occurs. Both boost and libc++ construct the end iterator. libstdc++ constructs a singular iterator which is not equal to the end iterator. For this reason we should clarify the state of the iterators after an error occurs.
Moved to P0/Ready during issues prioritization.
Friday: status to Immediate
This wording is relative to N4582.
Modify [fs.class.directory_iterator] as follows:
-3- If an iterator of type directory_iterator is advanced past the last directory element, that iterator shall become equal to the end iterator value. The directory_iterator default constructor shall create an iterator equal to the end iterator value, and this shall be the only valid iterator for the end condition.