How to implement an STL-style iterator and avoid common pitfalls?

I made a collection for which I want to provide an STL-style, random-access iterator. I was searching around for an example implementation of an iterator but I didn’t find any. I know about the need for const overloads of [] and * operators. What are the requirements for an iterator to be “STL-style” and what … Read more