Hi,
So one of the very nice things in C++11 is range-based for loops.
http://www.cprogramming.com/c 11/c 11-ranged-for-loop.html
Since it's so much clearer without being less expressive than the old-fashioned kind, it would be really nice to have a tool that could find eligible for loops and replace the for statement with an equivalent range statement.
So instead of
for (auto itElem = vec.begin(); itElem != vec.end(); ++itElem) {}
we would have
for (auto& elem : vec) {}
I guess the main trick is distinguishing the reference case from the copy case for the iterator, and making sure you don't change the semantics of any of the loops.
Thanks,
Jay