Changeset 636 in dev for trunk/ab5.0/abdev/BasicCompiler_Common/src/Compiler.cpp
- Timestamp:
- Jun 10, 2008, 11:40:17 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ab5.0/abdev/BasicCompiler_Common/src/Compiler.cpp
r632 r636 5 5 Compiler compiler; 6 6 7 Compiler::Compiler() 8 : isBuildSuccessful( false ) 9 , targetModuleType( ActiveBasic::Common::TargetModuleType::Exe ) 10 , isDebug( false ) 11 , isUnicode( false ) 12 , isCore( false ) 13 , currentRelationalObjectModuleIndexForSource( 0 ) 14 { 15 // 生成先のオブジェクトモジュールを登録 16 ObjectModule *pObjectModule = new ObjectModule(); 17 staticLibraries.push_back( pObjectModule ); 18 SelectObjectModule( pObjectModule ); 19 20 namespaceSupporter.RegistAllNamespaceScopesCollection( &GetObjectModule().meta.GetNamespaces() ); 21 22 Symbol::RegistNamespaceSupporter( &namespaceSupporter ); 23 } 24 Compiler::~Compiler() 25 { 26 BOOST_FOREACH( ObjectModule *pStaticLibrary, staticLibraries ) 27 { 28 delete pStaticLibrary; 29 } 30 staticLibraries.clear(); 31 } 32 33 void Compiler::PreStaticLink( const ObjectModules &staticLibraries ) 34 { 35 BOOST_FOREACH( const ObjectModule *pStaticLibrary, staticLibraries ) 36 { 37 // 関連オブジェクトモジュールの名前リスト 38 this->GetObjectModule().relationalObjectModuleNames.push_back( pStaticLibrary->GetName() ); 39 } 40 } 7 41 void Compiler::StaticLink( ObjectModules &staticLibraries ) 8 42 { 9 43 BOOST_FOREACH( ObjectModule *pStaticLibrary, staticLibraries ) 10 44 { 45 if( &this->GetObjectModule() == pStaticLibrary ) 46 { 47 // 自分自身の場合はリンクしない 48 continue; 49 } 50 11 51 // メタ情報 12 pNowObjectModule->StaticLink( *pStaticLibrary );52 this->GetObjectModule().StaticLink( *pStaticLibrary ); 13 53 } 14 54 }
Note:
See TracChangeset
for help on using the changeset viewer.