C++11 refactor: nullptr and range based for loops.