Changeset 533 in dev for trunk


Ignore:
Timestamp:
May 3, 2008, 4:22:35 PM (16 years ago)
Author:
dai_9181
Message:

Compiler::StartProcedureCompile、Compiler::FinishProcedureCompileメソッドを追加(要実装)。

Location:
trunk/ab5.0/abdev
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/ab5.0/abdev/BasicCompiler_Common/include/Compiler.h

    r524 r533  
    189189    // コンパイル中のクラス
    190190    const CClass *pCompilingClass;
     191
     192    void StartProcedureCompile( const UserProc *pUserProc );
     193    void FinishProcedureCompile();
    191194};
    192195
  • trunk/ab5.0/abdev/BasicCompiler_Common/src/Compiler.cpp

    r523 r533  
    210210    return (std::string)"(null)";
    211211}
     212
     213void Compiler::StartProcedureCompile( const UserProc *pUserProc )
     214{
     215    //コンパイル中の関数が属するクラス
     216    this->pCompilingClass = pUserProc->GetParentClassPtr();
     217
     218    //コンパイルスタートをクラス管理クラスに追加
     219    this->GetObjectModule().meta.GetClasses().StartCompile( pUserProc );
     220
     221    //コンパイル中の関数
     222    UserProc::CompileStartForUserProc( pUserProc );
     223
     224    // コンパイル中の関数が属する名前空間
     225    this->GetNamespaceSupporter().SetLivingNamespaceScopes( pUserProc->GetNamespaceScopes() );
     226
     227    // コンパイル中の関数でImportsされている名前空間
     228    this->GetNamespaceSupporter().SetImportedNamespaces( pUserProc->GetImportedNamespaces() );
     229
     230    // コード生成対象を選択
     231    this->codeGenerator.Select( (const_cast<UserProc *>(pUserProc))->GetNativeCode() );
     232}
     233void Compiler::FinishProcedureCompile()
     234{
     235}
  • trunk/ab5.0/abdev/compiler_x86/Compile_ProcOp.cpp

    r507 r533  
    313313    }
    314314
    315     //コンパイル中の関数が属するクラス
    316     compiler.pCompilingClass = pUserProc->GetParentClassPtr();
    317 
    318     //コンパイルスタートをクラス管理クラスに追加
    319     compiler.GetObjectModule().meta.GetClasses().StartCompile( pUserProc );
    320 
    321     //コンパイル中の関数
    322     UserProc::CompileStartForUserProc( pUserProc );
    323 
    324     // コンパイル中の関数が属する名前空間
    325     compiler.GetNamespaceSupporter().SetLivingNamespaceScopes( pUserProc->GetNamespaceScopes() );
    326 
    327     // コンパイル中の関数でImportsされている名前空間
    328     compiler.GetNamespaceSupporter().SetImportedNamespaces( pUserProc->GetImportedNamespaces() );
    329 
    330     // コード生成対象を選択
    331     compiler.codeGenerator.Select( (const_cast<UserProc *>(pUserProc))->GetNativeCode() );
     315    compiler.StartProcedureCompile( pUserProc );
    332316
    333317    if(pUserProc->IsSystem()){
     
    778762    SynonymErrorWords=0;
    779763
     764    compiler.FinishProcedureCompile();
     765
    780766
    781767    //ローカル変数のネーム情報は後に解放する
Note: See TracChangeset for help on using the changeset viewer.