Changeset 310 in dev


Ignore:
Timestamp:
Aug 29, 2007, 2:47:43 PM (17 years ago)
Author:
dai_9181
Message:

GetClass_recurメソッド内でImportsされた名前空間情報が適用されていなかったので適用した。

Location:
trunk/abdev/BasicCompiler_Common/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/abdev/BasicCompiler_Common/src/Class.cpp

    r305 r310  
    10971097    namespaceScopes.clear();
    10981098
     1099    // Importsされた名前空間の管理
     1100    NamespaceScopesCollection backupImportedNamespaces = compiler.GetNamespaceSupporter().GetImportedNamespaces();
     1101    compiler.GetNamespaceSupporter().GetImportedNamespaces().clear();
     1102
    10991103    // 呼び出し元でコンパイル中のクラスポインタをバックアップ
    11001104    const CClass *pBackCompilingClass = compiler.pCompilingClass;
     
    11261130
    11271131            i += 2;
     1132            continue;
     1133        }
     1134
     1135        else if( basbuf[i] == 1 && basbuf[i+1] == ESC_IMPORTS ){
     1136            for(i+=2,i2=0;;i2++,i++){
     1137                if( IsCommandDelimitation( basbuf[i] ) ){
     1138                    temporary[i2]=0;
     1139                    break;
     1140                }
     1141                temporary[i2]=basbuf[i];
     1142            }
     1143            if( !compiler.GetNamespaceSupporter().ImportsNamespace( temporary ) )
     1144            {
     1145                SmoothieException::Throw(64,temporary,i );
     1146            }
     1147
     1148            continue;
     1149        }
     1150        else if( basbuf[i] == 1 && basbuf[i+1] == ESC_CLEARNAMESPACEIMPORTED ){
     1151            compiler.GetNamespaceSupporter().GetImportedNamespaces().clear();
    11281152            continue;
    11291153        }
     
    15551579    // 名前空間を元に戻す
    15561580    compiler.GetNamespaceSupporter().GetLivingNamespaceScopes() = backupNamespaceScopes;
     1581
     1582    // インポートされた名前空間を元に戻す
     1583    compiler.GetNamespaceSupporter().GetImportedNamespaces() = backupImportedNamespaces;
    15571584}
    15581585void Classes::GetAllClassInfo(void){
  • trunk/abdev/BasicCompiler_Common/src/Procedure.cpp

    r306 r310  
    357357                while(sourceOfParams[i2]=='*') temporary[i3++]=sourceOfParams[i2++];
    358358                for(;;i2++,i3++){
    359                     if(!IsVariableChar(sourceOfParams[i2])){
     359                    if( IsCommandDelimitation( sourceOfParams[i2] ) )
     360                    {
    360361                        temporary[i3]=0;
    361362                        break;
Note: See TracChangeset for help on using the changeset viewer.