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/Level.cc

    r10821 r10916  
    106106    void Level::networkCallbackTemplatesChanged()
    107107    {
    108         for(const auto & elem : this->networkTemplateNames_)
    109         {
    110             assert(Template::getTemplate(elem));
    111             Template::getTemplate(elem)->applyOn(this);
     108        for(const std::string& name : this->networkTemplateNames_)
     109        {
     110            assert(Template::getTemplate(name));
     111            Template::getTemplate(name)->applyOn(this);
    112112        }
    113113    }
     
    135135        //       objects alive when ~Level is called. This is the reason why we cannot directly destroy() the Plugins - instead we need
    136136        //       to call destroyLater() to ensure that no instances from this plugin exist anymore.
    137         for (auto & elem : this->plugins_)
    138             (elem)->destroyLater();
     137        for (PluginReference* plugin : this->plugins_)
     138            plugin->destroyLater();
    139139        this->plugins_.clear();
    140140    }
     
    173173    {
    174174        unsigned int i = 0;
    175         for (const auto & elem : this->objects_)
     175        for (BaseObject* object : this->objects_)
    176176        {
    177177            if (i == index)
    178                 return (elem);
     178                return object;
    179179            ++i;
    180180        }
Note: See TracChangeset for help on using the changeset viewer.