- Timestamp:
- Jan 10, 2016, 1:54:11 PM (9 years ago)
- Location:
- code/branches/cpp11_v3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/cpp11_v3
- Property svn:mergeinfo changed
-
code/branches/cpp11_v3/src/libraries/core/NamespaceNode.cc
r8858 r11054 103 103 bool bFoundMatchingNamespace = false; 104 104 105 for ( std::map<std::string, NamespaceNode*>::iterator it = this->subnodes_.begin(); it != this->subnodes_.end(); ++it)105 for (const auto& mapEntry : this->subnodes_) 106 106 { 107 if ( it->first.find(firstPart) == (it->first.size() - firstPart.size()))107 if (mapEntry.first.find(firstPart) == (mapEntry.first.size() - firstPart.size())) 108 108 { 109 std::set<NamespaceNode*> temp2 = it->second->getNodeRelative(secondPart);109 std::set<NamespaceNode*> temp2 = mapEntry.second->getNodeRelative(secondPart); 110 110 nodes.insert(temp2.begin(), temp2.end()); 111 111 bFoundMatchingNamespace = true; … … 132 132 else 133 133 { 134 for ( std::map<std::string, NamespaceNode*>::const_iterator it = this->subnodes_.begin(); it != this->subnodes_.end(); ++it)135 if ( it->second->includes(ns))134 for (const auto& mapEntry : this->subnodes_) 135 if (mapEntry.second->includes(ns)) 136 136 return true; 137 137 } … … 149 149 150 150 int i = 0; 151 for ( std::map<std::string, NamespaceNode*>::const_iterator it = this->subnodes_.begin(); it != this->subnodes_.end(); i++, ++it)151 for (const auto& mapEntry : this->subnodes_) 152 152 { 153 153 if (i > 0) 154 154 output += ", "; 155 155 156 output += it->second->toString(); 156 output += mapEntry.second->toString(); 157 i++; 157 158 } 158 159 … … 167 168 std::string output = (indentation + this->name_ + '\n'); 168 169 169 for ( std::map<std::string, NamespaceNode*>::const_iterator it = this->subnodes_.begin(); it != this->subnodes_.end(); ++it)170 output += it->second->toString(indentation + " ");170 for (const auto& mapEntry : this->subnodes_) 171 output += mapEntry.second->toString(indentation + " "); 171 172 172 173 return output;
Note: See TracChangeset
for help on using the changeset viewer.