On March 21st the standards committee voted to approve the deprecation of std::iterator
proposed in P0174:
The long sequence of void arguments is much less clear to the reader than simply providing the expected
typedef
s in the class definition itself, which is the approach taken by the current working draft, following the pattern set in c++14
Before c++17 inheritance from std::iterator
was encouraged to remove the tedium from iterator boilerplate implementation. But the deprecation will require one of these things:
typedef
sauto
rather than depending upon the iterator to declare typesstd::iterator_traits
may be updated to work without inheriting from std::iterator
Can someone enlighten me on which of these options I should expect, as I design custom iterators with an eye towards c++17 compatibility?