Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 5, 2015, 10:47:51 PM (9 years ago)
Author:
landauf
Message:

use range-based for-loop where it makes sense (e.g. ObjectList)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/cpp11_v2/src/modules/invader/Invader.cc

    r10768 r10919  
    9898        if (player == nullptr)
    9999        {
    100             for (ObjectList<InvaderShip>::iterator it = ObjectList<InvaderShip>::begin(); it != ObjectList<InvaderShip>::end(); ++it)
    101                 player = *it;
     100            for (InvaderShip* ship : ObjectList<InvaderShip>())
     101                player = ship;
    102102        }
    103103        return player;
Note: See TracChangeset for help on using the changeset viewer.