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/modules/objects/triggers/MultiTrigger.cc

    r10765 r10821  
    504504    bool MultiTrigger::checkAnd(BaseObject* triggerer)
    505505    {
    506         for(std::set<TriggerBase*>::iterator it = this->children_.begin(); it != this->children_.end(); ++it)
    507         {
    508             TriggerBase* trigger = *it;
     506        for(auto trigger : this->children_)
     507        {
     508           
    509509            if(trigger->isMultiTrigger())
    510510            {
     
    531531    bool MultiTrigger::checkOr(BaseObject* triggerer)
    532532    {
    533         for(std::set<TriggerBase*>::iterator it = this->children_.begin(); it != this->children_.end(); ++it)
    534         {
    535             TriggerBase* trigger = *it;
     533        for(auto trigger : this->children_)
     534        {
     535           
    536536            if(trigger->isMultiTrigger())
    537537            {
     
    559559    {
    560560        bool triggered = false;
    561         for(std::set<TriggerBase*>::iterator it = this->children_.begin(); it != this->children_.end(); ++it)
    562         {
    563             TriggerBase* trigger = *it;
     561        for(auto trigger : this->children_)
     562        {
     563           
    564564            if(triggered)
    565565            {
Note: See TracChangeset for help on using the changeset viewer.