C++11ize iterator usage