Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 2, 2015, 11:22:03 PM (9 years ago)
Author:
landauf
Message:

use actual types instead of 'auto'. only exception is for complicated template types, e.g. when iterating over a map

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/cpp11_v2/src/orxonox/controllers/ArtificialController.cc

    r10768 r10916  
    231231    int ArtificialController::getFiremode(std::string name)
    232232    {
    233         for (auto firemode : this->weaponModes_)
    234         {
    235             if (firemode.first == name)
    236                 return firemode.second;
     233        for (auto& mapEntry : this->weaponModes_)
     234        {
     235            if (mapEntry.first == name)
     236                return mapEntry.second;
    237237        }
    238238        return -1;
Note: See TracChangeset for help on using the changeset viewer.