Why does reverse_iterator doubly define its nested types?
问题 It appears that the iterator adaptor reverse_iterator doubly defines most of its nested types. In particular, it inherits publicly from std::iterator which exposes iterator_category , value_type , difference_type , pointer and reference . Except for iterator_category and value_type , these are all explicitly typedef 'ed again in the class definition. 24.5.1.1 Class template reverse_iterator [reverse.iterator] namespace std { template <class Iterator> class reverse_iterator : public iterator