| 1070 | } |
| 1071 | |
| 1072 | void Namespace::getUniqueEntryLists(Namespace *other, VectorPtr<Entry *> *outThisList, VectorPtr<Entry *> *outOtherList) |
| 1073 | { |
| 1074 | // All namespace entries in the common ACR should be |
| 1075 | // ignored when checking for duplicate entry names. |
| 1076 | static VectorPtr<Namespace::Entry *> commonEntries; |
| 1077 | commonEntries.clear(); |
| 1078 | |
| 1079 | AbstractClassRep *commonACR = mClassRep->getCommonParent(other->mClassRep); |
| 1080 | commonACR->getNameSpace()->getEntryList(&commonEntries); |
| 1081 | |
| 1082 | // Make life easier |
| 1083 | VectorPtr<Namespace::Entry *> &thisEntries = *outThisList; |
| 1084 | VectorPtr<Namespace::Entry *> &compEntries = *outOtherList; |
| 1085 | |
| 1086 | // Clear, just in case they aren't |
| 1087 | thisEntries.clear(); |
| 1088 | compEntries.clear(); |
| 1089 | |
| 1090 | getEntryList(&thisEntries); |
| 1091 | other->getEntryList(&compEntries); |
| 1092 | |
| 1093 | // Run through all of the entries in the common ACR, and remove them from |
| 1094 | // the other two entry lists |
| 1095 | for (NamespaceEntryListIterator itr = commonEntries.begin(); itr != commonEntries.end(); itr++) |
| 1096 | { |
| 1097 | // Check this entry list |
| 1098 | for (NamespaceEntryListIterator thisItr = thisEntries.begin(); thisItr != thisEntries.end(); thisItr++) |
| 1099 | { |
| 1100 | if (*thisItr == *itr) |
| 1101 | { |
| 1102 | thisEntries.erase(thisItr); |
| 1103 | break; |
| 1104 | } |
| 1105 | } |
| 1106 | |
| 1107 | // Same check for component entry list |
| 1108 | for (NamespaceEntryListIterator compItr = compEntries.begin(); compItr != compEntries.end(); compItr++) |
| 1109 | { |
| 1110 | if (*compItr == *itr) |
| 1111 | { |
| 1112 | compEntries.erase(compItr); |
| 1113 | break; |
| 1114 | } |
| 1115 | } |
| 1116 | } |
| 1117 | } |
| 1118 | |
| 1119 | void Namespace::init() |
| 1120 | { |
nothing calls this directly
no test coverage detected