Ignore:
Timestamp:
Jan 22, 2007, 11:38:19 PM (18 years ago)
Author:
dai_9181
Message:

戻り値に基本型を持つインデクサ(Getter)が正常に呼び出せないバグを修正。

File:
1 edited

Legend:

Unmodified
Added
Removed
  • BasicCompiler_Common/Subroutine.cpp

    r31 r38  
    222222    return 1;
    223223}
     224
     225//インデクサ(getter)の戻り値を取得
     226bool GetReturnTypeOfIndexerGetterProc(CClass *pobj_Class,TYPEINFO &RetTypeInfo){
     227    SUBINFO **ppsi;
     228    int num;
     229    ppsi=pobj_Class->GetOperatorSubInfo(CALC_ARRAY_GET,num);
     230    if(num==0){
     231        HeapDefaultFree(ppsi);
     232
     233        return false;
     234    }
     235
     236    RetTypeInfo.type = ppsi[0]->ReturnType;
     237    RetTypeInfo.u.lpIndex = ppsi[0]->u.ReturnIndex;
     238
     239    HeapDefaultFree(ppsi);
     240
     241    return true;
     242}
     243
    224244
    225245void AddDeclareData(char *buffer,int NowLine){
Note: See TracChangeset for help on using the changeset viewer.