Changeset 380 in dev for trunk/abdev/BasicCompiler_Common/src/Class.cpp
- Timestamp:
- Dec 18, 2007, 2:51:10 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/abdev/BasicCompiler_Common/src/Class.cpp
r379 r380 1227 1227 } 1228 1228 1229 std::vector<const CClass *> classes; 1229 1230 const CClass *pClass = GetHashArrayElement( name.c_str() ); 1230 1231 while( pClass ) … … 1232 1233 if( pClass->IsEqualSymbol( namespaceScopes, name ) ){ 1233 1234 //名前空間とクラス名が一致した 1234 return pClass;1235 classes.push_back( pClass ); 1235 1236 } 1236 1237 pClass = pClass->GetChainNext(); 1238 } 1239 if( classes.size() > 0 ) 1240 { 1241 // 複数の名前空間の中に同一のクラス名が存在する場合があるので、アクセス可能で尚且つ階層が一番深いものをチョイスする 1242 pClass = classes.front(); 1243 1244 BOOST_FOREACH( const CClass *pTempClass, classes ) 1245 { 1246 if( pClass->GetNamespaceScopes().size() < pTempClass->GetNamespaceScopes().size() ) 1247 { 1248 pClass = pTempClass; 1249 } 1250 } 1251 1252 return pClass; 1237 1253 } 1238 1254
Note:
See TracChangeset
for help on using the changeset viewer.