On Fri, Nov 2, 2012 at 8:43 AM, Sebastian Messerschmidt
Bidirectional Iterators and rbegin/rend are not necessarily the same thing.
Understood. I mention rbegin()/rend() only to say that if boost::filesystem::path supported them, my question about boost::filesystem::path::end() would become moot because I would use the rbegin()/rend() idiom instead.
The bidirectional property only guarantees that the operator-- is supported [1] additionally to the ++ operator.
To be clear about my question, let me pose it as a syllogism, where 'container' is an instance of SomeContainer: IF SomeContainer::end() is documented to return a bidirectional iterator, AND container.end() != container.begin(), THEN the following code is valid, and references the last item in container: SomeContainer::const_iterator it = container.end(); --it; SomeContainer::value_type const& last = *it; Always true?