diff --git a/clif/testing/iterator.h b/clif/testing/iterator.h index c52c713..ca94c33 100644 --- a/clif/testing/iterator.h +++ b/clif/testing/iterator.h @@ -22,6 +22,7 @@ // It's using exceptions to demonstrate they are handled correctly by CLIF. #include +#include #include namespace clif_iterator_test { @@ -30,8 +31,14 @@ template class Ring { public: // Mimic std containers, so that Ring::const_iterator is a real thing. - class const_iterator: public std::iterator { + class const_iterator { public: + using value_type = T; + using difference_type = ptrdiff_t; + using pointer = T*; + using reference = T&; + using iterator_category = std::forward_iterator_tag; + // CLIF requires both or neither of copy/move constructors and copy/move // copy assignment operators. const_iterator(const const_iterator&) = default;