Ignore:
Timestamp:
Jun 14, 2008, 12:16:27 PM (16 years ago)
Author:
dai_9181
Message:

静的リンクリンカの依存関係解決モジュールを製作中

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ab5.0/abdev/ab_common/src/Lexical/Procedure.cpp

    r639 r640  
    1212}
    1313
    14 bool Procedure::Resolve( const ObjectModule &resolver )
     14bool Procedure::Resolve( const ObjectModule &resolver, ResolveErrors &resolveErrors )
    1515{
    1616    BOOST_FOREACH( Parameter *pParameter, params )
    1717    {
    18         pParameter->Resolve( resolver );
    19     }
    20 
    21     returnType.Resolve( resolver );
     18        pParameter->Resolve( resolver, resolveErrors );
     19    }
     20
     21    returnType.Resolve( resolver, resolveErrors );
    2222
    2323    return true;
     
    170170}
    171171
    172 bool UserProc::Resolve( const ObjectModule &resolver )
    173 {
    174     Procedure::Resolve( resolver );
    175 
    176     if( pParentClass )
    177     {
    178         if( pParentClass->IsNeedResolve() )
    179         {
    180             pParentClass = resolver.meta.GetClasses().FindLike( pParentClass );
     172bool UserProc::Resolve( const ObjectModule &resolver, ResolveErrors &resolveErrors )
     173{
     174    Procedure::Resolve( resolver, resolveErrors );
     175
     176    if( this->pParentClass )
     177    {
     178        if( this->pParentClass->IsNeedResolve() )
     179        {
     180            const CClass *pTempClass = resolver.meta.GetClasses().FindLike( this->pParentClass );
     181            if( pTempClass )
     182            {
     183                this->pParentClass = pTempClass;
     184            }
     185            else
     186            {
     187                resolveErrors.Add( ResolveError( this->pParentClass->GetRelationalObjectModuleIndex(), this->pParentClass->GetFullName() ) );
     188            }
    181189        }
    182190    }
     
    184192    if( pInterface )
    185193    {
    186         const_cast<Interface *>(pInterface)->Resolve( resolver );
     194        const_cast<Interface *>(pInterface)->Resolve( resolver, resolveErrors );
    187195    }
    188196
    189197    if( pMethod )
    190198    {
    191         pMethod->Resolve( resolver );
     199        pMethod->Resolve( resolver, resolveErrors );
    192200    }
    193201
    194202    BOOST_FOREACH( Parameter *pParameter, realParams )
    195203    {
    196         pParameter->Resolve( resolver );
     204        pParameter->Resolve( resolver, resolveErrors );
    197205    }
    198206
    199207    BOOST_FOREACH( Variable *pLocalVar, localVars )
    200208    {
    201         pLocalVar->Resolve( resolver );
    202     }
    203 
    204     nativeCode.Resolve( resolver );
     209        pLocalVar->Resolve( resolver, resolveErrors );
     210    }
     211
     212    nativeCode.Resolve( resolver, resolveErrors );
    205213    return true;
    206214}
     
    228236}
    229237
    230 bool DllProc::Resolve( const ObjectModule &resolver )
    231 {
    232     Procedure::Resolve( resolver );
    233     return true;
    234 }
    235 
    236 bool ProcPointer::Resolve( const ObjectModule &resolver )
    237 {
    238     Procedure::Resolve( resolver );
     238bool DllProc::Resolve( const ObjectModule &resolver, ResolveErrors &resolveErrors )
     239{
     240    Procedure::Resolve( resolver, resolveErrors );
     241    return true;
     242}
     243
     244bool ProcPointer::Resolve( const ObjectModule &resolver, ResolveErrors &resolveErrors )
     245{
     246    Procedure::Resolve( resolver, resolveErrors );
    239247    return true;
    240248}
Note: See TracChangeset for help on using the changeset viewer.