Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 21, 2015, 7:05:53 PM (8 years ago)
Author:
muemart
Message:

Run clang-modernize -loop-convert

  • Again, not all possible loops were converted
  • It can do pretty cool transformations, but I had to fix a few compile errors, so there might be some runtime errors lurking around too
File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/cpp11_v2/src/libraries/util/Serialise.h

    r8706 r10821  
    672672    {
    673673        uint32_t tempsize = sizeof(uint32_t); // for the number of entries
    674         for( typename std::set<T>::iterator it=((std::set<T>*)(&variable))->begin(); it!=((std::set<T>*)(&variable))->end(); ++it)
    675             tempsize += returnSize( *it );
     674        for(const auto & elem : *((std::set<T>*)(&variable)))
     675            tempsize += returnSize( elem );
    676676        return tempsize;
    677677    }
Note: See TracChangeset for help on using the changeset viewer.