comparison Framework/Loaders/LoaderCache.cpp @ 963:d358593820b8

removal of C++11 iterator
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 27 Aug 2019 08:15:36 +0200
parents 92e32e263ae9
children e704a53c9d0a
comparison
equal deleted inserted replaced
962:e70d75f199c5 963:d358593820b8
255 template<typename T> void DebugDisplayObjRefCountsInMap( 255 template<typename T> void DebugDisplayObjRefCountsInMap(
256 const std::string& name, const std::map<std::string, boost::shared_ptr<T> >& myMap) 256 const std::string& name, const std::map<std::string, boost::shared_ptr<T> >& myMap)
257 { 257 {
258 LOG(TRACE) << "Map \"" << name << "\" ref counts:"; 258 LOG(TRACE) << "Map \"" << name << "\" ref counts:";
259 size_t i = 0; 259 size_t i = 0;
260 for (const auto& it : myMap) 260 for (typename std::map<std::string, boost::shared_ptr<T> >::const_iterator
261 { 261 it = myMap.begin(); it != myMap.end(); ++it)
262 auto ptr = it.second; 262 {
263 LOG(TRACE) << " element #" << i << ": ref count = " << it.second.use_count(); 263 LOG(TRACE) << " element #" << i << ": ref count = " << it->second.use_count();
264 i++; 264 i++;
265 } 265 }
266 } 266 }
267 267
268 void LoaderCache::DebugDisplayObjRefCounts() 268 void LoaderCache::DebugDisplayObjRefCounts()