Index: code/branches/cpp11_v2/src/orxonox/controllers/ArtificialController.cc
===================================================================
--- code/branches/cpp11_v2/src/orxonox/controllers/ArtificialController.cc	(revision 10821)
+++ code/branches/cpp11_v2/src/orxonox/controllers/ArtificialController.cc	(revision 10916)
@@ -231,8 +231,8 @@
     int ArtificialController::getFiremode(std::string name)
     {
-        for (auto firemode : this->weaponModes_)
-        {
-            if (firemode.first == name)
-                return firemode.second;
+        for (auto& mapEntry : this->weaponModes_)
+        {
+            if (mapEntry.first == name)
+                return mapEntry.second;
         }
         return -1;
Index: code/branches/cpp11_v2/src/orxonox/controllers/FormationController.cc
===================================================================
--- code/branches/cpp11_v2/src/orxonox/controllers/FormationController.cc	(revision 10821)
+++ code/branches/cpp11_v2/src/orxonox/controllers/FormationController.cc	(revision 10916)
@@ -440,8 +440,8 @@
                 if(newMaster->slaves_.size() > this->maxFormationSize_) continue;
 
-                for(auto & elem : this->slaves_)
+                for(FormationController* slave : this->slaves_)
                 {
-                    (elem)->myMaster_ = newMaster;
-                    newMaster->slaves_.push_back(elem);
+                    slave->myMaster_ = newMaster;
+                    newMaster->slaves_.push_back(slave);
                 }
                 this->slaves_.clear();
@@ -486,5 +486,5 @@
             int i = 1;
 
-            for(auto & elem : slaves_)
+            for(FormationController* slave : slaves_)
             {
                 pos = Vector3::ZERO;
@@ -497,6 +497,6 @@
                     dest+=FORMATION_LENGTH*(orient*WorldEntity::BACK);
                 }
-                (elem)->setTargetOrientation(orient);
-                (elem)->setTargetPosition(pos);
+                slave->setTargetOrientation(orient);
+                slave->setTargetPosition(pos);
                 left=!left;
             }
@@ -569,8 +569,8 @@
         if(this->state_ != MASTER) return;
 
-        for(auto & elem : slaves_)
-        {
-            (elem)->state_ = FREE;
-            (elem)->myMaster_ = nullptr;
+        for(FormationController* slave : slaves_)
+        {
+            slave->state_ = FREE;
+            slave->myMaster_ = nullptr;
         }
         this->slaves_.clear();
@@ -584,10 +584,10 @@
         if(this->state_ != MASTER) return;
 
-        for(auto & elem : slaves_)
-        {
-            (elem)->state_ = FREE;
-            (elem)->forceFreedom();
-            (elem)->targetPosition_ = this->targetPosition_;
-            (elem)->bShooting_ = true;
+        for(FormationController* slave : slaves_)
+        {
+            slave->state_ = FREE;
+            slave->forceFreedom();
+            slave->targetPosition_ = this->targetPosition_;
+            slave->bShooting_ = true;
 //             (*it)->getControllableEntity()->fire(0);// fire once for fun
         }
@@ -650,7 +650,7 @@
             this->slaves_.push_back(this->myMaster_);
             //set this as new master
-            for(auto & elem : slaves_)
-            {
-                 (elem)->myMaster_=this;
+            for(FormationController* slave : slaves_)
+            {
+                 slave->myMaster_=this;
             }
             this->myMaster_=nullptr;
@@ -694,9 +694,9 @@
         if (this->state_ == MASTER)
         {
-            for(auto & elem : slaves_)
-            {
-                 (elem)->formationMode_ = val;
+            for(FormationController* slave : slaves_)
+            {
+                 slave->formationMode_ = val;
                  if (val == ATTACK)
-                     (elem)->forgetTarget();
+                     slave->forgetTarget();
             }
         }
Index: code/branches/cpp11_v2/src/orxonox/controllers/WaypointController.cc
===================================================================
--- code/branches/cpp11_v2/src/orxonox/controllers/WaypointController.cc	(revision 10821)
+++ code/branches/cpp11_v2/src/orxonox/controllers/WaypointController.cc	(revision 10916)
@@ -44,8 +44,8 @@
     WaypointController::~WaypointController()
     {
-        for (auto & elem : this->waypoints_)
+        for (WorldEntity* waypoint : this->waypoints_)
         {
-            if(elem)
-                elem->destroy();
+            if(waypoint)
+                waypoint->destroy();
         }
     }
