According to the docs here this iterator is a LegacyInputIterator, which is a LegacyIterator. Now, according to my understanding of the meaning of 'legacy', it means this:
In computing, a legacy system is an old method, technology, computer system, or application program, "of, relating to, or being a previous or outdated computer system,"[1] yet still in use. - Wikipedia
- of or pertaining to old or outdated computer hardware, software, or data that, while still functional, does not work well with up-to-date systems. - Dictionary
So in my code to iterator through some folders I do this:
std::filesystem::directory_iterator iter{ "c:/folder" };
while (iter != std::filesystem::directory_iterator{})
{
// Do something with the file
++iter;
}
I'm just wondering if there's a better or newer way of doing this, as I have suspicions over the use of the term legacy for the iterators I'm using.