Ignore:
Timestamp:
May 10, 2007, 12:27:41 PM (17 years ago)
Author:
dai_9181
Message:

TypeDef、Declareの名前空間対応を行った。
TypeDef、Declareをローカル領域で使用した際、エラーを表示するようにした。

File:
1 edited

Legend:

Unmodified
Added
Removed
  • BasicCompiler_Common/Procedure.cpp

    r108 r113  
    539539}
    540540
     541bool DllProc::IsEqualSymbol( const NamespaceScopes &namespaceScopes, const string &name ) const
     542{
     543    if( GetName() != name ){
     544        return false;
     545    }
     546    return NamespaceScopes::IsSameArea( this->namespaceScopes, namespaceScopes );
     547}
     548bool DllProc::IsEqualSymbol( const string &fullName ) const
     549{
     550    char AreaName[VN_SIZE] = "";        //オブジェクト変数
     551    char NestName[VN_SIZE] = "";        //入れ子メンバ
     552    bool isNest = SplitMemberName( fullName.c_str(), AreaName, NestName );
     553
     554    if( IsEqualSymbol( NamespaceScopes( AreaName ), NestName ) ){
     555        return true;
     556    }
     557
     558    if( isNest ){
     559        // 静的メンバを考慮
     560
     561        char AreaName2[VN_SIZE] = "";       //オブジェクト変数
     562        char NestName2[VN_SIZE] = "";       //入れ子メンバ
     563        bool isNest = SplitMemberName( AreaName, AreaName2, NestName2 );
     564        lstrcat( NestName2, "." );
     565        lstrcat( NestName2, NestName );
     566
     567        return IsEqualSymbol( NamespaceScopes( AreaName2 ), NestName2 );
     568    }
     569
     570    return false;
     571}
     572
     573
    541574bool DllProc::SetParamsAndReturnType( const char *sourceOfParams, int nowLine ){
    542575    int i = 0;
Note: See TracChangeset for help on using the changeset viewer.