Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Aug 11, 2013, 2:36:31 PM (11 years ago)
Author:
landauf
Message:

reset static maps and variables after destroying identifiers
iterate over the same map in createClassHierarchy() an in destroyAllIdentifiers()

Location:
code/branches/core6/src/libraries/core/class
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core6/src/libraries/core/class/Identifier.h

    r9632 r9634  
    294294            {
    295295                SuperFunctionDestruction<0, T>::destroy(this);
     296                classIdentifier_s = 0;
    296297            }
    297298
  • code/branches/core6/src/libraries/core/class/IdentifierManager.cc

    r9632 r9634  
    8686        orxout(internal_status) << "Create class-hierarchy" << endl;
    8787        IdentifierManager::startCreatingHierarchy();
    88         for (std::map<std::string, Identifier*>::const_iterator it = IdentifierManager::getStringIdentifierMap().begin(); it != IdentifierManager::getStringIdentifierMap().end(); ++it)
     88        for (std::map<std::string, Identifier*>::const_iterator it = IdentifierManager::getTypeIDIdentifierMap().begin(); it != IdentifierManager::getTypeIDIdentifierMap().end(); ++it)
    8989        {
    9090            // To create the new branch of the class-hierarchy, we create a new object and delete it afterwards.
     
    106106        for (std::map<std::string, Identifier*>::iterator it = IdentifierManager::getTypeIDIdentifierMap().begin(); it != IdentifierManager::getTypeIDIdentifierMap().end(); ++it)
    107107            delete (it->second);
     108
     109        IdentifierManager::getTypeIDIdentifierMap().clear();
     110        IdentifierManager::getStringIdentifierMapIntern().clear();
     111        IdentifierManager::getLowercaseStringIdentifierMapIntern().clear();
     112        IdentifierManager::getIDIdentifierMapIntern().clear();
    108113    }
    109114
Note: See TracChangeset for help on using the changeset viewer.