Changeset 73 in dev for BasicCompiler_Common
- Timestamp:
- Mar 16, 2007, 11:07:14 PM (18 years ago)
- Location:
- BasicCompiler_Common
- Files:
-
- 22 edited
Legend:
- Unmodified
- Added
- Removed
-
BasicCompiler_Common/BasicCompiler.h
r69 r73 24 24 DWORD ImageBase; 25 25 INCLUDEFILEINFO IncludeFileInfo; 26 S UBINFO**ppSubHash;26 SubInfo **ppSubHash; 27 27 int SubNum; 28 28 char **ppMacroNames; -
BasicCompiler_Common/Class.cpp
r71 r73 267 267 staticMembers.push_back( member ); 268 268 } 269 void CClass::AddMethod( S UBINFO*psi,DWORD dwAccess, bool isConst, BOOL bAbstract, BOOL bVirtual ){269 void CClass::AddMethod( SubInfo *psi,DWORD dwAccess, bool isConst, BOOL bAbstract, BOOL bVirtual ){ 270 270 CMethod *method = new CMethod(); 271 271 method->psi = psi; … … 278 278 methods.push_back( method ); 279 279 } 280 void CClass::AddStaticMethod(S UBINFO*psi,DWORD dwAccess){280 void CClass::AddStaticMethod(SubInfo *psi,DWORD dwAccess){ 281 281 CMethod *method = new CMethod(); 282 282 method->psi=psi; … … 322 322 return 0; 323 323 } 324 CMethod *CClass::GetMethodInfo( S UBINFO*psi ){324 CMethod *CClass::GetMethodInfo( SubInfo *psi ){ 325 325 for( int i=(int)methods.size()-1; i>=0; i-- ){ 326 326 if( psi == methods[i]->psi ) return methods[i]; … … 328 328 return NULL; 329 329 } 330 CMethod *CClass::GetStaticMethodInfo( S UBINFO*psi ){330 CMethod *CClass::GetStaticMethodInfo( SubInfo *psi ){ 331 331 for( int i=(int)staticMethods.size()-1; i>=0; i-- ){ 332 332 if( psi == staticMethods[i]->psi ) return staticMethods[i]; … … 347 347 } 348 348 349 void CClass::EnumStaticMethod( const char *methodName, std::vector<S UBINFO*> &subs ) const349 void CClass::EnumStaticMethod( const char *methodName, std::vector<SubInfo *> &subs ) const 350 350 { 351 351 foreach( CMethod *method, staticMethods ){ … … 356 356 } 357 357 358 void CClass::EnumMethod( const char *methodName, std::vector<S UBINFO*> &subs ) const358 void CClass::EnumMethod( const char *methodName, std::vector<SubInfo *> &subs ) const 359 359 { 360 360 //オブジェクトのメンバ関数の場合 … … 367 367 } 368 368 369 void CClass::EnumMethod( const BYTE idOperatorCalc, std::vector<S UBINFO*> &subs ) const369 void CClass::EnumMethod( const BYTE idOperatorCalc, std::vector<SubInfo *> &subs ) const 370 370 { 371 371 //オブジェクトのメンバ関数の場合 372 372 //※オーバーライドされた関数を先にサーチする必要があるため、バックサーチを行う 373 373 for( int i=(int)methods.size()-1; i>=0; i-- ){ 374 S UBINFO*psi = methods[i]->psi;374 SubInfo *psi = methods[i]->psi; 375 375 char *temp = psi->name; 376 376 if(temp[0]==1&&temp[1]==ESC_OPERATOR){ … … 508 508 509 509 510 int CClass::GetFuncNumInVtbl( const S UBINFO*psi ) const510 int CClass::GetFuncNumInVtbl( const SubInfo *psi ) const 511 511 { 512 512 int n = 0; … … 527 527 ////////////////////////////////////// 528 528 529 S UBINFO**ppsi;530 ppsi=(S UBINFO **)HeapAlloc(hHeap,0,vtbl_num*sizeof(SUBINFO*));529 SubInfo **ppsi; 530 ppsi=(SubInfo **)HeapAlloc(hHeap,0,vtbl_num*sizeof(SubInfo *)); 531 531 532 532 //関数テーブルに値をセット … … 565 565 int i; 566 566 for(i=0;i<vtbl_num;i++){ 567 S UBINFO*psi;568 psi=(S UBINFO*)pVtbl[i];567 SubInfo *psi; 568 psi=(SubInfo *)pVtbl[i]; 569 569 if(!psi) continue; 570 570 pVtbl[i]=psi->CompileAddress+ImageBase+MemPos_CodeSection; … … 835 835 836 836 //関数ハッシュへ登録 837 S UBINFO*psi;837 SubInfo *psi; 838 838 psi=AddSubData(buffer,NowLine,bVirtual,pobj_c,bStatic); 839 839 if(!psi) return; … … 849 849 850 850 //標準コンストラクタ(引数なし) 851 if(psi-> ParmNum==0) fConstructor=1;851 if(psi->params.size()==0) fConstructor=1; 852 852 853 853 //強制的にConst修飾子をつける … … 894 894 895 895 if(lstrcmp(temporary,method->psi->name)==0){ 896 if(CompareParameter( 897 method->psi->pParmInfo,method->psi->ParmNum, 898 psi->pParmInfo,psi->ParmNum 899 )==0){ 896 if( Parameter::Equals( method->psi->params, psi->params ) ){ 900 897 //関数名、パラメータ属性が合致したとき 901 898 SetError(15,psi->name,NowLine); … … 911 908 foreach( CMethod *method, pobj_c->methods ){ 912 909 if(lstrcmp(temporary,method->psi->name)==0){ 913 if(CompareParameter( 914 method->psi->pParmInfo,method->psi->ParmNum, 915 psi->pParmInfo,psi->ParmNum 916 )==0){ 910 if( Parameter::Equals( method->psi->params, psi->params ) ){ 917 911 918 912 if(method->psi->bVirtual){ … … 1444 1438 } 1445 1439 1446 void CDBClass::StartCompile( S UBINFO*psi ){1440 void CDBClass::StartCompile( SubInfo *psi ){ 1447 1441 pCompilingClass = psi->pobj_ParentClass; 1448 1442 if( pCompilingClass ){ -
BasicCompiler_Common/Class.h
r71 r73 2 2 3 3 class CClass; 4 struct SUBINFO;4 class SubInfo; 5 5 6 6 //データ型 … … 48 48 class CMethod{ 49 49 public: 50 S UBINFO*psi;50 SubInfo *psi; 51 51 DWORD dwAccess; 52 52 BOOL bAbstract; … … 116 116 void AddMember( DWORD dwAccess, bool idConst, bool isRef, char *buffer ); 117 117 void AddStaticMember( DWORD dwAccess, bool isConst, bool isRef, char *buffer, int NowLine ); 118 void AddMethod( S UBINFO*psi,DWORD dwAccess, bool isConst, BOOL bAbstract, BOOL bVirtual );119 void AddStaticMethod(S UBINFO*psi,DWORD dwAccess);118 void AddMethod( SubInfo *psi,DWORD dwAccess, bool isConst, BOOL bAbstract, BOOL bVirtual ); 119 void AddStaticMethod(SubInfo *psi,DWORD dwAccess); 120 120 121 121 //重複チェック … … 124 124 125 125 //メソッド取得 126 CMethod *GetMethodInfo( S UBINFO*psi );127 CMethod *GetStaticMethodInfo( S UBINFO*psi );126 CMethod *GetMethodInfo( SubInfo *psi ); 127 CMethod *GetStaticMethodInfo( SubInfo *psi ); 128 128 129 129 //メソッドの存在を確認 … … 132 132 133 133 //メソッドを列挙 134 void EnumStaticMethod( const char *methodName, std::vector<S UBINFO*> &subs ) const;135 void EnumMethod( const char *methodName, std::vector<S UBINFO*> &subs ) const;136 void EnumMethod( const BYTE idOperatorCalc, std::vector<S UBINFO*> &subs ) const;134 void EnumStaticMethod( const char *methodName, std::vector<SubInfo *> &subs ) const; 135 void EnumMethod( const char *methodName, std::vector<SubInfo *> &subs ) const; 136 void EnumMethod( const BYTE idOperatorCalc, std::vector<SubInfo *> &subs ) const; 137 137 138 138 //デフォルト コンストラクタ メソッドを取得 … … 157 157 long vtbl_offset; 158 158 public: 159 int GetFuncNumInVtbl( const S UBINFO*psi ) const;159 int GetFuncNumInVtbl( const SubInfo *psi ) const; 160 160 LONG_PTR GetVtblGlobalOffset(void); 161 161 void ActionVtblSchedule(LONG_PTR ImageBase, LONG_PTR MemPos_CodeSection); … … 245 245 public: 246 246 //コンパイル開始の通知を受け取るメソッド 247 void StartCompile( S UBINFO*psi );247 void StartCompile( SubInfo *psi ); 248 248 249 249 //現在コンパイル中のメソッド情報を取得 -
BasicCompiler_Common/Debug.cpp
r4 r73 224 224 SendDlgItemMessage(hMainDlg,IDC_DEBUGLIST,EM_REPLACESEL,0,(LPARAM)buffer); 225 225 } 226 S UBINFO*GetSubFromObp(ULONG_PTR pos){227 extern S UBINFO**ppSubHash;228 S UBINFO*psi;226 SubInfo *GetSubFromObp(ULONG_PTR pos){ 227 extern SubInfo **ppSubHash; 228 SubInfo *psi; 229 229 int i2; 230 230 … … 447 447 pobj_dti=new CDebugThreadInfo(); 448 448 449 S UBINFO*psi;449 SubInfo *psi; 450 450 451 451 extern DWORD dwStepRun; … … 681 681 if(!bRet) MessageBox(hMainDlg,"プロセスメモリーの読み込みに失敗","error",MB_OK); 682 682 683 extern S UBINFO*pSub_DebugSys_EndProc;683 extern SubInfo *pSub_DebugSys_EndProc; 684 684 if((BYTE)temporary[0]==0xE8&& 685 685 *((long *)(temporary+1))+5==(long)rva_to_real(pSub_DebugSys_EndProc->CompileAddress)-(long)EIP_RIP(Context)){ -
BasicCompiler_Common/DebugMiddleFile.cpp
r64 r73 213 213 214 214 //プロシージャ情報 215 extern S UBINFO**ppSubHash;215 extern SubInfo **ppSubHash; 216 216 extern int SubNum; 217 S UBINFO*psi;217 SubInfo *psi; 218 218 *(long *)(buffer+i2)=SubNum; 219 219 i2+=sizeof(long); … … 585 585 586 586 //プロシージャ情報 587 S UBINFO*psi;587 SubInfo *psi; 588 588 SubNum=*(long *)(buffer+i2); 589 589 i2+=sizeof(long); 590 ppSubHash=(S UBINFO **)HeapAlloc(hHeap,HEAP_ZERO_MEMORY,MAX_HASH*sizeof(SUBINFO*));590 ppSubHash=(SubInfo **)HeapAlloc(hHeap,HEAP_ZERO_MEMORY,MAX_HASH*sizeof(SubInfo *)); 591 591 for(i3=0;i3<SubNum;i3++){ 592 psi =(SUBINFO *)HeapAlloc(hHeap,0,sizeof(SUBINFO));592 psi = new SubInfo(); 593 593 psi->pNextData=0; 594 594 … … 618 618 i2+=sizeof(long); 619 619 620 psi->ParmNum=0;621 psi->pParmInfo=0;622 psi->RealParmNum=0;623 psi->pRealParmInfo=0;624 620 psi->bCompile=1; 625 621 … … 677 673 i4=hash_default(psi->name); 678 674 679 S UBINFO*psi2;675 SubInfo *psi2; 680 676 if(ppSubHash[i4]){ 681 677 psi2=ppSubHash[i4]; … … 804 800 805 801 806 extern S UBINFO**ppSubHash;802 extern SubInfo **ppSubHash; 807 803 ppSubHash=this->ppSubHash; 808 804 pSub_DebugSys_EndProc=GetSubHash("_DebugSys_EndProc"); … … 973 969 extern char **ppMacroNames; 974 970 ppMacroNames=0; 975 extern S UBINFO**ppSubHash;971 extern SubInfo **ppSubHash; 976 972 extern int SubNum; 977 973 ppSubHash=this->ppSubHash; 978 974 SubNum=this->SubNum; 979 975 980 extern S UBINFO*pSub_DebugSys_EndProc;976 extern SubInfo *pSub_DebugSys_EndProc; 981 977 pSub_DebugSys_EndProc=this->pSub_DebugSys_EndProc; 982 978 … … 998 994 999 995 //ローカル変数に関する情報を解放 1000 S UBINFO*psi;996 SubInfo *psi; 1001 997 for(i2=0;i2<MAX_HASH;i2++){ 1002 998 psi=ppSubHash[i2]; -
BasicCompiler_Common/DebugSection.h
r15 r73 49 49 50 50 //プロシージャ 51 S UBINFO**ppSubHash;51 SubInfo **ppSubHash; 52 52 int SubNum; 53 53 54 S UBINFO*pSub_DebugSys_EndProc;54 SubInfo *pSub_DebugSys_EndProc; 55 55 56 56 //ネイティブコードバッファ -
BasicCompiler_Common/LexicalScoping.cpp
r64 r73 226 226 227 227 //call free 228 extern S UBINFO*pSub_free;228 extern SubInfo *pSub_free; 229 229 op_call(pSub_free); 230 230 -
BasicCompiler_Common/MakeExe.cpp
r15 r73 223 223 224 224 //ローカル変数に関する情報を解放 225 extern S UBINFO**ppSubHash;226 S UBINFO*psi;225 extern SubInfo **ppSubHash; 226 SubInfo *psi; 227 227 for(i2=0;i2<MAX_HASH;i2++){ 228 228 psi=ppSubHash[i2]; … … 238 238 239 239 //サブルーチン(ユーザー定義)情報のメモリ解放 240 extern S UBINFO**ppSubHash;240 extern SubInfo **ppSubHash; 241 241 extern char **ppMacroNames; 242 242 extern int MacroNum; -
BasicCompiler_Common/NumOpe_GetType.cpp
r69 r73 193 193 pobj_c=(CClass *)index_stack[sp-2]; 194 194 195 std::vector<S UBINFO*> subs;195 std::vector<SubInfo *> subs; 196 196 pobj_c->EnumMethod( idCalc, subs ); 197 197 if( subs.size() == 0 ){ … … 230 230 if(idCalc==CALC_EQUAL) lstrcpy(temporary,"=="); 231 231 else GetCalcName(idCalc,temporary); 232 S UBINFO*psi;232 SubInfo *psi; 233 233 psi=OverloadSolution(temporary,subs,ppi,iParmNum,pBaseTypeInfo); 234 234 … … 240 240 else{ 241 241 //オーバーロードされていないが、パラメータ個数が一致しないとき 242 if(iParmNum!=psi-> ParmNum){242 if(iParmNum!=psi->params.size()){ 243 243 HeapDefaultFree(ppi); 244 244 return 0; … … 299 299 } 300 300 301 int NumOpe_GetType (char *Command,TYPEINFO *pBaseType,LONG_PTR *plpIndex){301 int NumOpe_GetType_Old( const char *Command,TYPEINFO *pBaseType,LONG_PTR *plpIndex){ 302 302 extern int cp; 303 303 int i,i2,i3,i4; … … 454 454 455 455 //マクロ関数の場合 456 i2=NumOpe_GetType (temp3,NULL,&index_stack[sp]);456 i2=NumOpe_GetType_Old(temp3,NULL,&index_stack[sp]); 457 457 458 458 if(!IS_LITERAL(index_stack[sp])){ … … 740 740 return RetType; 741 741 } 742 743 bool NumOpe_GetType( const char *expression, const Type &baseType, Type &resultType ){ 744 TYPEINFO baseTypeInfo = { 745 baseType.GetBasicType(), 746 baseType.GetIndex() 747 }; 748 LONG_PTR lpIndex; 749 int basicType = NumOpe_GetType_Old( expression, 750 baseType.IsNull() ? NULL:&baseTypeInfo, 751 &lpIndex ); 752 753 resultType.SetBasicType( basicType ); 754 resultType.SetIndex( lpIndex ); 755 756 return ( basicType != -1 ); 757 } -
BasicCompiler_Common/Object.cpp
r63 r73 19 19 pobj_c=(CClass *)TypeInfo.u.lpIndex; 20 20 21 S UBINFO*psi;21 SubInfo *psi; 22 22 psi=GetMethodHash(ObjectName,pobj_c->name,Parameter); 23 23 if(!psi){ -
BasicCompiler_Common/Overload.cpp
r71 r73 7 7 #endif 8 8 9 S UBINFO*OverloadSolutionWithStrParam(9 SubInfo *OverloadSolutionWithStrParam( 10 10 const char *name, 11 std::vector<S UBINFO*> &subs,11 std::vector<SubInfo *> &subs, 12 12 const char *Parameter, 13 13 const char *ObjectName, … … 37 37 */ 38 38 //パラメータオブジェクトを生成 39 if(lstrcmp(Parameter,"\"test\"")==0){ 40 int i=0; 41 } 39 42 pobj_parameter=new ParamImpl(Parameter); 40 43 if(pReturnTypeInfo) pobj_parameter->SetReturnType(pReturnTypeInfo); 41 44 42 45 43 S UBINFO*psi;46 SubInfo *psi; 44 47 psi=pobj_parameter->OverloadSolution(name,subs); 45 48 … … 52 55 } 53 56 54 S UBINFO*OverloadSolution(57 SubInfo *OverloadSolution( 55 58 const char *name, 56 std::vector<S UBINFO*> &subs,59 std::vector<SubInfo *> &subs, 57 60 const PARAMETER_INFO *ppi, 58 61 const int ParmNum, … … 68 71 if(pReturnTypeInfo) pobj_Parameter->SetReturnType(pReturnTypeInfo); 69 72 70 S UBINFO*psi;73 SubInfo *psi; 71 74 psi=pobj_Parameter->OverloadSolution(name,subs); 72 75 -
BasicCompiler_Common/PESchedule.cpp
r44 r73 220 220 221 221 CSubAddrSchedule::CSubAddrSchedule(){ 222 ppsi=(S UBINFO**)HeapAlloc(hHeap,0,1);222 ppsi=(SubInfo **)HeapAlloc(hHeap,0,1); 223 223 pbCall=(BOOL *)HeapAlloc(hHeap,0,1); 224 224 } … … 228 228 } 229 229 230 void CSubAddrSchedule::add(S UBINFO*psi,BOOL bCall){230 void CSubAddrSchedule::add(SubInfo *psi,BOOL bCall){ 231 231 if(!psi) return; 232 232 233 ppsi=(S UBINFO **)HeapReAlloc(hHeap,0,ppsi,(num+1)*sizeof(SUBINFO*));233 ppsi=(SubInfo **)HeapReAlloc(hHeap,0,ppsi,(num+1)*sizeof(SubInfo *)); 234 234 ppsi[num]=psi; 235 235 pbCall=(BOOL *)HeapReAlloc(hHeap,0,pbCall,(num+1)*sizeof(BOOL)); … … 282 282 CTempSchedule *pobj_TempSchedule; 283 283 284 -
BasicCompiler_Common/PESchedule.h
r34 r73 79 79 class CSubAddrSchedule:public CSchedule{ 80 80 public: 81 S UBINFO**ppsi;81 SubInfo **ppsi; 82 82 BOOL *pbCall; 83 83 … … 85 85 ~CSubAddrSchedule(); 86 86 87 void add(S UBINFO*psi,BOOL bCall);87 void add(SubInfo *psi,BOOL bCall); 88 88 }; 89 89 extern CSubAddrSchedule *pobj_SubAddrSchedule; -
BasicCompiler_Common/ParamImpl.cpp
r71 r73 73 73 ReturnTypeInfo.u.lpIndex=-1; 74 74 } 75 ParamImpl::ParamImpl(const Parameters ¶ms){ 76 int count = 0; 77 foreach( Parameter *pParam, params ){ 78 types[count].type = pParam->GetBasicType(); 79 types[count].u.lpIndex = pParam->GetIndex(); 80 count++; 81 } 82 this->ParmsNum=params.size(); 83 84 ReturnTypeInfo.type=DEF_NON; 85 ReturnTypeInfo.u.lpIndex=-1; 86 } 75 87 ParamImpl::~ParamImpl(){ 76 88 int i2; … … 88 100 } 89 101 90 BOOL ParamImpl::_overload_check( PARAMETER_INFO *ppi,int pi_num,TYPEINFO *pReturnTypeInfo,int overload_level){102 BOOL ParamImpl::_overload_check( Parameters ¶ms,TYPEINFO *pReturnTypeInfo,int overload_level){ 91 103 //パラメータを識別してオーバーロードを解決 92 104 93 105 //パラメータの個数が不一致の場合 94 if(pi_num!=ParmsNum) return 0; 95 96 int i,type; 97 LONG_PTR lpIndex; 98 for(i=0;i<pi_num;i++){ 106 int max = (int)params.size(); 107 if(max!=ParmsNum) return 0; 108 109 Type argType; 110 for(int i=0;i<max;i++){ 111 Parameter ¶m = *params[i]; 112 99 113 if(Parms[i]){ 100 TYPEINFO BaseType={ppi[i].type,ppi[i].u.index}; 101 type=NumOpe_GetType(Parms[i], 102 (overload_level==OVERLOAD_LEVEL0) ? NULL : &BaseType, 103 &lpIndex); 114 Type nullParam( DEF_NON ); 115 116 NumOpe_GetType(Parms[i], 117 (overload_level==OVERLOAD_LEVEL0)? nullParam : param, 118 argType); 104 119 } 105 120 else{ 106 type=types[i].type; 107 lpIndex=types[i].u.lpIndex; 108 } 109 110 if(type!=ppi[i].type){ 121 argType.SetType( types[i].type, types[i].u.lpIndex ); 122 } 123 124 if(argType.GetBasicType()!=param.GetBasicType()){ 111 125 if(overload_level==OVERLOAD_LEVEL1 || overload_level == OVERLOAD_LEVEL0){ 112 126 return 0; … … 114 128 else if(overload_level==OVERLOAD_LEVEL2){ 115 129 if(!( 116 IsWholeNumberType( type)&&IsWholeNumberType(ppi[i].type)||117 IsRealNumberType( type)&&IsRealNumberType(ppi[i].type)130 IsWholeNumberType(argType.GetBasicType())&&IsWholeNumberType(param.GetBasicType())|| 131 IsRealNumberType(argType.GetBasicType())&&IsRealNumberType(param.GetBasicType()) 118 132 )) return 0; 119 133 } 120 134 else if(overload_level==OVERLOAD_LEVEL3){ 121 if( type==DEF_OBJECT||ppi[i].type==DEF_OBJECT) return 0;135 if(argType.GetBasicType()==DEF_OBJECT||param.GetBasicType()==DEF_OBJECT) return 0; 122 136 } 123 137 } 124 138 else{ 125 if(NATURAL_TYPE( type)==DEF_OBJECT || NATURAL_TYPE(type)==DEF_STRUCT){126 if( lpIndex!=ppi[i].u.index) return 0;139 if(NATURAL_TYPE(argType.GetBasicType())==DEF_OBJECT || NATURAL_TYPE(argType.GetBasicType())==DEF_STRUCT){ 140 if(argType.GetIndex()!=param.GetIndex()) return 0; 127 141 } 128 142 } … … 143 157 } 144 158 145 S UBINFO *ParamImpl::OverloadSolutionWithReturnType( const char *name, std::vector<SUBINFO*> &subs ){159 SubInfo *ParamImpl::OverloadSolutionWithReturnType( const char *name, std::vector<SubInfo *> &subs ){ 146 160 int sw=0; 147 S UBINFO*psi;161 SubInfo *psi; 148 162 psi=0; 149 163 150 164 for( int level=OVERLOAD_MIN_LEVEL; level<=OVERLOAD_MAX_LEVEL; level++ ){ 151 foreach( S UBINFO*temp_psi, subs ){165 foreach( SubInfo *temp_psi, subs ){ 152 166 153 167 TYPEINFO ReturnTypeInfo; … … 156 170 157 171 //エラーチェック 158 if(_overload_check(temp_psi->p ParmInfo,temp_psi->ParmNum,&ReturnTypeInfo,level)){172 if(_overload_check(temp_psi->params,&ReturnTypeInfo,level)){ 159 173 if(sw){ 160 174 SetError(52,name,cp); … … 178 192 return psi; 179 193 } 180 S UBINFO *ParamImpl::OverloadSolution( const char *name, std::vector<SUBINFO*> &subs ){194 SubInfo *ParamImpl::OverloadSolution( const char *name, std::vector<SubInfo *> &subs ){ 181 195 int sw=0; 182 S UBINFO*psi;196 SubInfo *psi; 183 197 psi=0; 184 198 185 199 for( int level=OVERLOAD_MIN_LEVEL; level<=OVERLOAD_MAX_LEVEL; level++ ){ 186 200 187 foreach( S UBINFO*temp_psi, subs ){201 foreach( SubInfo *temp_psi, subs ){ 188 202 189 203 //エラーチェック 190 if(_overload_check(temp_psi->p ParmInfo,temp_psi->ParmNum,NULL,level)){204 if(_overload_check(temp_psi->params,NULL,level)){ 191 205 if(sw){ 192 206 return OverloadSolutionWithReturnType(name,subs); … … 202 216 203 217 if(!sw){ 204 S UBINFO*temp_psi;218 SubInfo *temp_psi; 205 219 foreach( temp_psi, subs ){ 206 220 207 221 //エラーチェック 208 if(temp_psi-> ParmNum==this->ParmsNum){222 if(temp_psi->params.size()==this->ParmsNum){ 209 223 if(sw){ 210 224 sw=0; … … 258 272 return 1; 259 273 } 274 bool ParamImpl::ErrorCheck( const char *procName, const Parameters ¶ms, int SecondParmNum ){ 275 if(ParmsNum>(int)params.size()){ 276 if(params[params.size()-1]->GetBasicType()!=DEF_ELLIPSE){ 277 //パラメータが多すぎるとき 278 SetError(10,procName,cp); 279 return false; 280 } 281 } 282 else if(ParmsNum<(int)params.size()){ 283 if(ParmsNum<SecondParmNum){ 284 if(params[ParmsNum]->GetBasicType()==DEF_ELLIPSE){ 285 return true; 286 } 287 288 //パラメータが少なすぎるとき 289 SetError(10,procName,cp); 290 return false; 291 } 292 293 //省略パラメータに "0" を指定する 294 for(;ParmsNum < (int)params.size();ParmsNum++){ 295 extern HANDLE hHeap; 296 char temporary[64]; 297 if(params[ParmsNum]->IsRef() == false) lstrcpy(temporary,"0"); 298 else sprintf(temporary,"%c%c0",1,ESC_BYVAL); 299 Parms[ParmsNum]=(char *)HeapAlloc(hHeap,0,lstrlen(temporary)+1); 300 lstrcpy(Parms[ParmsNum],temporary); 301 } 302 } 303 304 return true; 305 } 260 306 261 307 void ParamImpl::MacroParameterSupport(PARAMETER_INFO *ppi){ 262 int i; 263 for(i=0;i<ParmsNum;i++){ 308 for(int i=0;i<ParmsNum;i++){ 264 309 if(Parms[i][0]=='\0'){ 265 310 extern HANDLE hHeap; … … 273 318 } 274 319 } 320 void ParamImpl::MacroParameterSupport( const Parameters ¶ms ){ 321 for(int i=0;i<ParmsNum;i++){ 322 if(Parms[i][0]=='\0'){ 323 extern HANDLE hHeap; 324 char temporary[64]; 325 if( params[i]->IsRef() == false ) lstrcpy(temporary,"0"); 326 else sprintf(temporary,"%c%c0",1,ESC_BYVAL); 327 HeapDefaultFree(Parms[i]); 328 Parms[i]=(char *)HeapAlloc(hHeap,0,lstrlen(temporary)+1); 329 lstrcpy(Parms[i],temporary); 330 } 331 } 332 } -
BasicCompiler_Common/Parameter.h
r71 r73 5 5 6 6 class Parameter; 7 typedef vector<Parameter > Parameters;7 typedef vector<Parameter *> Parameters; 8 8 9 9 class Parameter : public Type … … 16 16 public: 17 17 Parameter( const string &varName, const Type &type, bool isRef = false ): 18 Type( type ) 18 Type( type ), 19 varName( varName ), 20 isRef( isRef ), 21 isArray( false ) 19 22 { 20 this->varName = varName; 21 this->isRef = isRef; 22 isArray = false; 23 subScripts[0] = -1; 24 } 25 Parameter( const Parameter ¶m ): 26 Type( param ), 27 varName( param.varName ), 28 isRef( param.isRef ), 29 isArray( false ) 30 { 31 subScripts[0] = -1; 32 if( param.isArray ){ 33 SetArray( param.subScripts ); 34 } 23 35 } 24 36 ~Parameter(){} … … 27 39 isArray = true; 28 40 memcpy( this->subScripts, pSubScripts, sizeof(int) * MAX_ARRAYDIM ); 41 } 42 43 const string &GetVarName() const 44 { 45 return varName; 29 46 } 30 47 … … 46 63 else{ 47 64 48 if( this->isRef && this-> BasicType() == DEF_ANY &&65 if( this->isRef && this->GetBasicType() == DEF_ANY && 49 66 param.isRef == false && param.IsPointer() 50 67 || 51 68 this->isRef == false && this->IsPointer() && 52 param.isRef && param. BasicType() == DEF_ANY ){69 param.isRef && param.GetBasicType() == DEF_ANY ){ 53 70 /* ByRef var As Any 54 71 と … … 71 88 int max = (int)paramsA.size(); 72 89 for( int i=0; i<max; i++ ){ 73 if( !paramsA[i] .Equals(paramsB[i] ) ){90 if( !paramsA[i]->Equals( *paramsB[i] ) ){ 74 91 return false; 75 92 } -
BasicCompiler_Common/Subroutine.cpp
r69 r73 8 8 9 9 //コンパイル中の関数情報 10 S UBINFO*pCompilingSubInfo;10 SubInfo *pCompilingSubInfo; 11 11 12 12 int GetCallProcName(char *buffer,char *name){ … … 114 114 ///////////////////// 115 115 116 S UBINFO *psi;117 p si=(SUBINFO*)pInfo;116 SubInfo *pSub; 117 pSub=(SubInfo *)pInfo; 118 118 119 119 //GetSubHash内でエラー提示が行われた場合 120 if(p si==(SUBINFO*)-1) return -1;120 if(pSub==(SubInfo *)-1) return -1; 121 121 122 122 … … 131 131 //////////////////////// 132 132 133 std::vector<S UBINFO*> subs;133 std::vector<SubInfo *> subs; 134 134 GetOverloadSubHash(name,subs); 135 135 if(subs.size()){ 136 136 //オーバーロードを解決 137 p si=OverloadSolutionWithStrParam(name,subs,Parameter,ObjectName,NULL);138 139 if(!p si) return 0;140 } 141 142 143 Opcode_CallProc(Parameter,p si,0,ObjectName,RefType);137 pSub=OverloadSolutionWithStrParam(name,subs,Parameter,ObjectName,NULL); 138 139 if(!pSub) return 0; 140 } 141 142 143 Opcode_CallProc(Parameter,pSub,0,ObjectName,RefType); 144 144 if( plpRetIndex ){ 145 *plpRetIndex = p si->u.ReturnIndex;146 } 147 return p si->ReturnType;145 *plpRetIndex = pSub->u.ReturnIndex; 146 } 147 return pSub->ReturnType; 148 148 } 149 149 else if(idProc==PROC_DLL){ … … 197 197 198 198 //オーバーロード用の関数リストを作成 199 std::vector<S UBINFO*> subs;199 std::vector<SubInfo *> subs; 200 200 GetOverloadSubHash(VarName,subs); 201 201 if(subs.size()==0){ … … 213 213 214 214 //オーバーロードを解決 215 S UBINFO *psi;216 p si=OverloadSolutionWithStrParam(VarName,subs,Parameter,ObjectName,NULL);217 218 if(p si){215 SubInfo *pSub; 216 pSub=OverloadSolutionWithStrParam(VarName,subs,Parameter,ObjectName,NULL); 217 218 if(pSub){ 219 219 //呼び出し 220 Opcode_CallProc(Parameter,p si,0,ObjectName,RefType);220 Opcode_CallProc(Parameter,pSub,0,ObjectName,RefType); 221 221 222 222 if( pRetTypeInfo ){ 223 pRetTypeInfo->type = p si->ReturnType;224 pRetTypeInfo->u.lpIndex = p si->u.ReturnIndex;223 pRetTypeInfo->type = pSub->ReturnType; 224 pRetTypeInfo->u.lpIndex = pSub->u.ReturnIndex; 225 225 } 226 226 } … … 240 240 ///////////////////// 241 241 242 S UBINFO *psi;243 p si=(SUBINFO*)pInfo;242 SubInfo *pSub; 243 pSub=(SubInfo *)pInfo; 244 244 245 245 //GetSubHash内でエラー提示が行われた場合 246 if(p si==(SUBINFO*)-1) return -1;246 if(pSub==(SubInfo *)-1) return -1; 247 247 248 248 … … 257 257 //////////////////////// 258 258 259 std::vector<S UBINFO*> subs;259 std::vector<SubInfo *> subs; 260 260 GetOverloadSubHash(name,subs); 261 261 if( subs.size() > 0 ){ 262 262 //オーバーロードを解決 263 p si=OverloadSolutionWithStrParam(name,subs,Parameter,ObjectName,NULL);264 265 if(!p si) return 0;266 } 267 268 269 ret_type=p si->ReturnType;270 *plpRetIndex=p si->u.ReturnIndex;263 pSub=OverloadSolutionWithStrParam(name,subs,Parameter,ObjectName,NULL); 264 265 if(!pSub) return 0; 266 } 267 268 269 ret_type=pSub->ReturnType; 270 *plpRetIndex=pSub->u.ReturnIndex; 271 271 } 272 272 else if(idProc==PROC_DLL){ … … 318 318 319 319 //オーバーロード用の関数リストを作成 320 std::vector<S UBINFO*> subs;320 std::vector<SubInfo *> subs; 321 321 GetOverloadSubHash(VarName,subs); 322 322 if(subs.size()==0){ … … 334 334 335 335 //オーバーロードを解決 336 S UBINFO *psi;337 p si=OverloadSolutionWithStrParam(VarName,subs,Parameter,ObjectName,NULL);338 339 if(p si){336 SubInfo *pSub; 337 pSub=OverloadSolutionWithStrParam(VarName,subs,Parameter,ObjectName,NULL); 338 339 if(pSub){ 340 340 if(pRetTypeInfo){ 341 pRetTypeInfo->type=p si->ReturnType;342 pRetTypeInfo->u.lpIndex=p si->u.ReturnIndex;341 pRetTypeInfo->type=pSub->ReturnType; 342 pRetTypeInfo->u.lpIndex=pSub->u.ReturnIndex; 343 343 } 344 344 } … … 349 349 //インデクサ(getter)の戻り値を取得 350 350 bool GetReturnTypeOfIndexerGetterProc(CClass *pobj_Class,TYPEINFO &RetTypeInfo){ 351 std::vector<S UBINFO*> subs;351 std::vector<SubInfo *> subs; 352 352 pobj_Class->EnumMethod( CALC_ARRAY_GET, subs ); 353 353 if( subs.size() == 0 ){ … … 644 644 return 0; 645 645 } 646 S UBINFO*AddSubData(char *buffer,int NowLine,BOOL bVirtual,CClass *pobj_c,BOOL bStatic){646 SubInfo *AddSubData(char *buffer,int NowLine,BOOL bVirtual,CClass *pobj_c,BOOL bStatic){ 647 647 int i,i2,i3,sw; 648 648 DWORD dwType; … … 761 761 SubNum++; 762 762 763 SUBINFO *psi; 764 psi=(SUBINFO *)HeapAlloc(hHeap,HEAP_ZERO_MEMORY,sizeof(SUBINFO)); 763 SubInfo *pSub = new SubInfo(); 765 764 766 765 //クラス名 767 p si->pobj_ParentClass=pobj_c;766 pSub->pobj_ParentClass=pobj_c; 768 767 769 768 //ID 770 769 static int id_base=0; 771 p si->id=(id_base++);770 pSub->id=(id_base++); 772 771 773 772 //関数名 774 p si->name=(char *)HeapAlloc(hHeap,0,lstrlen(temporary)+1);775 lstrcpy(p si->name,temporary);773 pSub->name=(char *)HeapAlloc(hHeap,0,lstrlen(temporary)+1); 774 lstrcpy(pSub->name,temporary); 776 775 777 776 //ソースコードの位置 778 p si->address=NowLine;779 780 p si->bExport=bExport;781 p si->bCdecl=bCdecl;782 p si->bVirtual=bVirtual;783 if(bExport) p si->bUse=1;784 else p si->bUse=0;785 p si->bCompile=0;786 p si->bSystem=0;787 788 p si->dwType=dwType;789 790 791 if(p si->dwType==SUBTYPE_FUNCTION){777 pSub->address=NowLine; 778 779 pSub->bExport=bExport; 780 pSub->bCdecl=bCdecl; 781 pSub->bVirtual=bVirtual; 782 if(bExport) pSub->bUse=1; 783 else pSub->bUse=0; 784 pSub->bCompile=0; 785 pSub->bSystem=0; 786 787 pSub->dwType=dwType; 788 789 790 if(pSub->dwType==SUBTYPE_FUNCTION){ 792 791 /////////////////// 793 792 // 戻り値を取得 794 793 /////////////////// 795 794 796 p si->isReturnRef = false;795 pSub->isReturnRef = false; 797 796 798 797 if(pobj_c){ 799 if(lstrcmp(p si->name,pobj_c->name)==0||800 p si->name[0]=='~'){798 if(lstrcmp(pSub->name,pobj_c->name)==0|| 799 pSub->name[0]=='~'){ 801 800 //クラスのコンストラクタ、デストラクタがFunction定義の場合はエラーをだす 802 801 SetError(115,NULL,NowLine); … … 814 813 if( buffer[i2-2] == 1 && buffer[i2-1] == ESC_BYREF ){ 815 814 //参照型 816 p si->isReturnRef = true;815 pSub->isReturnRef = true; 817 816 } 818 817 … … 827 826 temporary[i3]=buffer[i2]; 828 827 } 829 p si->ReturnType=GetTypeFixed(temporary,&psi->u.ReturnIndex);830 if(p si->ReturnType==DEF_NON) SetError(3,temporary,NowLine);828 pSub->ReturnType=GetTypeFixed(temporary,&pSub->u.ReturnIndex); 829 if(pSub->ReturnType==DEF_NON) SetError(3,temporary,NowLine); 831 830 832 831 sw_as=1; … … 836 835 837 836 if(!sw_as){ 838 SetError(-104,p si->name,NowLine);839 840 p si->ReturnType=DEF_DOUBLE;837 SetError(-104,pSub->name,NowLine); 838 839 pSub->ReturnType=DEF_DOUBLE; 841 840 } 842 841 } 843 842 else{ 844 843 //戻り値なしのSub定義 845 psi->ReturnType=DEF_NON; 846 psi->u.ReturnIndex=-1; 847 } 848 849 850 851 psi->pParmInfo=(PARAMETER_INFO *)HeapAlloc(hHeap,HEAP_ZERO_MEMORY,sizeof(PARAMETER_INFO)*2); 852 psi->ParmNum=0; 844 pSub->ReturnType=DEF_NON; 845 pSub->u.ReturnIndex=-1; 846 } 853 847 854 848 //パラメータ … … 860 854 if(buffer[i]!=')'&&pobj_c){ 861 855 //クラスのメンバ関数の場合のみ、デストラクタにパラメータがある場合にエラーをだす 862 if(p si->name[0]=='~'){856 if(pSub->name[0]=='~'){ 863 857 SetError(114,NULL,NowLine); 864 858 i=JumpStringInPare(buffer,i); … … 868 862 if(buffer[i]==')') break; 869 863 870 psi->pParmInfo=(PARAMETER_INFO *)HeapReAlloc(hHeap,0,psi->pParmInfo,(psi->ParmNum+1)*sizeof(PARAMETER_INFO)); 871 872 //ByVal 864 //ByRef 865 bool isRef; 873 866 if(buffer[i]==1&&buffer[i+1]==ESC_BYVAL){ 874 psi->pParmInfo[psi->ParmNum].bByVal=1;867 isRef = false; 875 868 i+=2; 876 869 } 877 870 else if(buffer[i]==1&&buffer[i+1]==ESC_BYREF){ 878 psi->pParmInfo[psi->ParmNum].bByVal=0;871 isRef = true; 879 872 i+=2; 880 873 } 881 else psi->pParmInfo[psi->ParmNum].bByVal=1;874 else isRef = false; 882 875 883 876 //パラメータ名 877 bool isArray = false; 878 int subScripts[MAX_ARRAYDIM]; 879 char name[VN_SIZE]; 884 880 sw=0; 885 881 for(i2=0;;i++,i2++){ … … 887 883 if(!sw) sw=1; 888 884 889 i3=GetStringInPare( temporary+i2,buffer+i);885 i3=GetStringInPare(name+i2,buffer+i); 890 886 i2+=i3-1; 891 887 i+=i3-1; … … 895 891 if(!sw) sw=1; 896 892 897 i3=GetStringInBracket( temporary+i2,buffer+i);893 i3=GetStringInBracket(name+i2,buffer+i); 898 894 i2+=i3-1; 899 895 i+=i3-1; … … 901 897 } 902 898 if(!IsVariableChar(buffer[i])){ 903 temporary[i2]=0;899 name[i2]=0; 904 900 break; 905 901 } 906 temporary[i2]=buffer[i];902 name[i2]=buffer[i]; 907 903 } 908 904 if(sw){ 909 905 //配列パラメータ 910 if( psi->pParmInfo[psi->ParmNum].bByVal) SetError(29,NULL,NowLine);911 psi->pParmInfo[psi->ParmNum].bArray=1;912 913 if(( temporary[i2-2]=='('&&temporary[i2-1]==')')||914 ( temporary[i2-2]=='['&&temporary[i2-1]==']')){915 psi->pParmInfo[psi->ParmNum].SubScripts[0]=LONG_MAX;916 psi->pParmInfo[psi->ParmNum].SubScripts[1]=-1;917 918 temporary[i2-2]=0;906 if( isRef == false ) SetError(29,NULL,NowLine); 907 isArray = true; 908 909 if((name[i2-2]=='('&&name[i2-1]==')')|| 910 (name[i2-2]=='['&&name[i2-1]==']')){ 911 subScripts[0]=LONG_MAX; 912 subScripts[1]=-1; 913 914 name[i2-2]=0; 919 915 } 920 916 else{ 921 GetArrange(temporary,temp2,psi->pParmInfo[psi->ParmNum].SubScripts); 922 lstrcpy(temporary,temp2); 923 } 924 925 i2=lstrlen(temporary); 926 } 927 else{ 928 psi->pParmInfo[psi->ParmNum].bArray=0; 929 psi->pParmInfo[psi->ParmNum].SubScripts[0]=-1; 930 } 931 psi->pParmInfo[psi->ParmNum].name=(char *)HeapAlloc(hHeap,0,i2+1); 932 lstrcpy(psi->pParmInfo[psi->ParmNum].name,temporary); 917 GetArrange(name,temp2,subScripts); 918 lstrcpy(name,temp2); 919 } 920 921 i2=lstrlen(name); 922 } 933 923 934 924 //型 925 Type type( DEF_NON ); 935 926 if(buffer[i]==1&&buffer[i+1]==ESC_AS){ 936 927 i+=2; … … 955 946 } 956 947 957 psi->pParmInfo[psi->ParmNum].type= 958 GetTypeFixed(temporary,&psi->pParmInfo[psi->ParmNum].u.index); 948 Type::StringToType( temporary, type ); 959 949 960 950 if(temporary[0]=='*'&& … … 963 953 if(buffer[i]!='('){ 964 954 SetError(10,temporary,NowLine); 965 return 0;955 break; 966 956 } 967 957 i3=GetStringInPare(temporary+i2,buffer+i); … … 986 976 } 987 977 988 if( psi->pParmInfo[psi->ParmNum].type==-1){978 if( type.IsNull() ){ 989 979 SetError(3,temporary,NowLine); 990 psi->pParmInfo[psi->ParmNum].type=DEF_PTR_VOID; 991 } 992 993 /*未完成(構造体パラメータを値参照として渡してよいものか!?) 994 if(psi->pParmInfo[psi->ParmNum].type==DEF_OBJECT){ 995 if(psi->pParmInfo[psi->ParmNum].bByVal) SetError(28,temporary,NowLine); 996 }*/ 980 type.SetBasicType( DEF_PTR_VOID ); 981 } 997 982 } 998 983 else{ 999 psi->pParmInfo[psi->ParmNum].type=GetTypeFromSimpleName(temporary);984 type.SetBasicType( GetTypeFromSimpleName(temporary) ); 1000 985 SetError(-103,temporary,NowLine); 1001 986 } 1002 987 1003 if( psi->pParmInfo[psi->ParmNum].type==DEF_PTR_PROC){988 if( type.IsProcPtr() ){ 1004 989 //関数ポインタの場合 1005 psi->pParmInfo[psi->ParmNum].u.index=AddProcPtrInfo(temporary+3,temporary[2]); 1006 } 1007 1008 //パラメータの数を更新 1009 psi->ParmNum++; 990 type.SetIndex( AddProcPtrInfo(temporary+3,temporary[2]) ); 991 } 992 993 Parameter *pParam = new Parameter( name, type, isRef ); 994 if( isArray ){ 995 pParam->SetArray( subScripts ); 996 } 997 998 //パラメータを追加 999 pSub->params.push_back( pParam ); 1010 1000 1011 1001 if(buffer[i]==','){ … … 1016 1006 else{ 1017 1007 SetError(1,NULL,NowLine); 1018 return 0;1019 } 1020 } 1021 p si->SecondParmNum=psi->ParmNum;1008 break; 1009 } 1010 } 1011 pSub->SecondParmNum = (int)pSub->params.size(); 1022 1012 i++; 1023 1013 if(buffer[i]=='('){ … … 1026 1016 if(buffer[i]==')') break; 1027 1017 1028 psi->pParmInfo=(PARAMETER_INFO *)HeapReAlloc(hHeap,0,psi->pParmInfo,(psi->ParmNum+1)*sizeof(PARAMETER_INFO)); 1029 1030 //ByVal 1018 //ByRef 1019 bool isRef; 1031 1020 if(buffer[i]==1&&buffer[i+1]==ESC_BYVAL){ 1032 psi->pParmInfo[psi->ParmNum].bByVal=1;1021 isRef = false; 1033 1022 i+=2; 1034 1023 } 1035 1024 else if(buffer[i]==1&&buffer[i+1]==ESC_BYREF){ 1036 psi->pParmInfo[psi->ParmNum].bByVal=0;1025 isRef = true; 1037 1026 i+=2; 1038 1027 } 1039 else psi->pParmInfo[psi->ParmNum].bByVal=1;1028 else isRef = false; 1040 1029 1041 1030 //パラメータ名 1031 bool isArray = false; 1032 int subScripts[MAX_ARRAYDIM]; 1033 char name[VN_SIZE]; 1042 1034 sw=0; 1043 1035 for(i2=0;;i++,i2++){ … … 1045 1037 if(!sw) sw=1; 1046 1038 1047 i3=GetStringInPare( temporary+i2,buffer+i);1039 i3=GetStringInPare(name+i2,buffer+i); 1048 1040 i2+=i3-1; 1049 1041 i+=i3-1; … … 1053 1045 if(!sw) sw=1; 1054 1046 1055 i3=GetStringInBracket( temporary+i2,buffer+i);1047 i3=GetStringInBracket(name+i2,buffer+i); 1056 1048 i2+=i3-1; 1057 1049 i+=i3-1; … … 1059 1051 } 1060 1052 if(!IsVariableChar(buffer[i])){ 1061 temporary[i2]=0;1053 name[i2]=0; 1062 1054 break; 1063 1055 } 1064 temporary[i2]=buffer[i];1056 name[i2]=buffer[i]; 1065 1057 } 1066 1058 if(sw){ 1067 1059 //配列パラメータ 1068 if( psi->pParmInfo[psi->ParmNum].bByVal) SetError(29,NULL,NowLine);1069 psi->pParmInfo[psi->ParmNum].bArray=1;1070 1071 if(( temporary[i2-2]=='('&&temporary[i2-1]==')')||1072 ( temporary[i2-2]=='['&&temporary[i2-1]==']')){1073 psi->pParmInfo[psi->ParmNum].SubScripts[0]=LONG_MAX;1074 psi->pParmInfo[psi->ParmNum].SubScripts[1]=-1;1075 1076 temporary[i2-2]=0;1060 if( isRef == false ) SetError(29,NULL,NowLine); 1061 isArray = true; 1062 1063 if((name[i2-2]=='('&&name[i2-1]==')')|| 1064 (name[i2-2]=='['&&name[i2-1]==']')){ 1065 subScripts[0]=LONG_MAX; 1066 subScripts[1]=-1; 1067 1068 name[i2-2]=0; 1077 1069 } 1078 1070 else{ 1079 GetArrange(temporary,temp2,psi->pParmInfo[psi->ParmNum].SubScripts); 1080 lstrcpy(temporary,temp2); 1081 } 1082 1083 i2=lstrlen(temporary); 1084 } 1085 else{ 1086 psi->pParmInfo[psi->ParmNum].bArray=0; 1087 psi->pParmInfo[psi->ParmNum].SubScripts[0]=-1; 1088 } 1089 psi->pParmInfo[psi->ParmNum].name=(char *)HeapAlloc(hHeap,0,i2+1); 1090 lstrcpy(psi->pParmInfo[psi->ParmNum].name,temporary); 1071 GetArrange(name,temp2,subScripts); 1072 lstrcpy(name,temp2); 1073 } 1074 1075 i2=lstrlen(name); 1076 } 1091 1077 1092 1078 //型 1079 Type type( DEF_NON ); 1093 1080 if(buffer[i]==1&&buffer[i+1]==ESC_AS){ 1094 1081 i+=2; 1082 1095 1083 i2=0; 1096 1084 while(buffer[i]=='*'){ … … 1101 1089 for(;;i++,i2++){ 1102 1090 if(!IsVariableChar(buffer[i])){ 1091 if(buffer[i]==1&&(buffer[i+1]==ESC_FUNCTION||buffer[i+1]==ESC_SUB)){ 1092 temporary[i2++]=buffer[i++]; 1093 temporary[i2]=buffer[i]; 1094 continue; 1095 } 1103 1096 temporary[i2]=0; 1104 1097 break; … … 1106 1099 temporary[i2]=buffer[i]; 1107 1100 } 1108 psi->pParmInfo[psi->ParmNum].type= 1109 GetTypeFixed(temporary,&psi->pParmInfo[psi->ParmNum].u.index); 1110 if(psi->pParmInfo[psi->ParmNum].type==-1) SetError(3,temporary,NowLine); 1101 1102 Type::StringToType( temporary, type ); 1103 1104 if(temporary[0]=='*'&& 1105 temporary[1]==1&& 1106 (temporary[2]==ESC_FUNCTION||temporary[2]==ESC_SUB)){ 1107 if(buffer[i]!='('){ 1108 SetError(10,temporary,NowLine); 1109 break; 1110 } 1111 i3=GetStringInPare(temporary+i2,buffer+i); 1112 i+=i3; 1113 i2+=i3; 1114 1115 if(temporary[2]==ESC_FUNCTION&&buffer[i]==1&&buffer[i+1]==ESC_AS){ 1116 temporary[i2++]=buffer[i++]; 1117 temporary[i2++]=buffer[i++]; 1118 for(;;i++,i2++){ 1119 if(!IsVariableChar(buffer[i])){ 1120 temporary[i2]=0; 1121 break; 1122 } 1123 temporary[i2]=buffer[i]; 1124 } 1125 } 1126 } 1127 else{ 1128 //TypeDefをする前のベース型を取得 1129 GetOriginalTypeName(temporary); 1130 } 1131 1132 if( type.IsNull() ){ 1133 SetError(3,temporary,NowLine); 1134 type.SetBasicType( DEF_PTR_VOID ); 1135 } 1111 1136 } 1112 1137 else{ 1113 psi->pParmInfo[psi->ParmNum].type=GetTypeFromSimpleName(temporary);1138 type.SetBasicType( GetTypeFromSimpleName(temporary) ); 1114 1139 SetError(-103,temporary,NowLine); 1115 1140 } 1116 1141 1117 psi->ParmNum++; 1142 if( type.IsProcPtr() ){ 1143 //関数ポインタの場合 1144 type.SetIndex( AddProcPtrInfo(temporary+3,temporary[2]) ); 1145 } 1146 1147 Parameter *pParam = new Parameter( name, type, isRef ); 1148 if( isArray ){ 1149 pParam->SetArray( subScripts ); 1150 } 1151 1152 //パラメータを追加 1153 pSub->params.push_back( pParam ); 1118 1154 1119 1155 if(buffer[i]==','){ … … 1124 1160 else{ 1125 1161 SetError(1,NULL,NowLine); 1126 return 0;1162 break; 1127 1163 } 1128 1164 } … … 1130 1166 } 1131 1167 1132 //リアルパラメータ領域を取得(_System_LocalThisを考慮して2つだけ多く確保する) 1133 psi->pRealParmInfo=(PARAMETER_INFO *)HeapAlloc(hHeap,0,(psi->ParmNum+2)*sizeof(PARAMETER_INFO)); 1134 psi->RealParmNum=0; 1168 //リアルパラメータ領域を取得(_System_LocalThisを考慮して2つだけ多く確保する場合がある) 1135 1169 1136 1170 if(pobj_c&&bStatic==0){ 1137 i = psi->RealParmNum;1138 1139 1171 //オブジェクトメンバの場合は、第一パラメータを_System_LocalThis引き渡し用として利用 1140 psi->pRealParmInfo[i].name = "_System_LocalThis"; 1141 psi->pRealParmInfo[i].type=DEF_PTR_VOID; 1142 psi->pRealParmInfo[i].u.index=-1; 1143 psi->pRealParmInfo[i].bByVal=1; 1144 psi->pRealParmInfo[i].bArray=0; 1145 psi->pRealParmInfo[i].SubScripts[0]=-1; 1146 1147 psi->RealParmNum++; 1148 } 1149 1150 if(psi->ReturnType==DEF_STRUCT){ 1151 i = psi->RealParmNum; 1152 1172 string name = "_System_LocalThis"; 1173 Type type( DEF_PTR_VOID ); 1174 pSub->realParams.push_back( new Parameter( name, type ) ); 1175 } 1176 1177 if(pSub->ReturnType==DEF_STRUCT){ 1153 1178 //構造体を戻り値として持つ場合 1154 1179 //※第一パラメータ(Thisポインタありの場合は第二パラメータ)を戻り値用の参照宣言にする 1155 1180 1156 if(psi->name[0]==1&&psi->name[1]==ESC_OPERATOR) 1157 psi->pRealParmInfo[i].name="_System_ReturnValue"; 1158 else psi->pRealParmInfo[i].name=psi->name; 1159 psi->pRealParmInfo[i].type=DEF_STRUCT; 1160 psi->pRealParmInfo[i].u.index=psi->u.ReturnIndex; 1161 psi->pRealParmInfo[i].bByVal=0; 1162 psi->pRealParmInfo[i].bArray=0; 1163 psi->pRealParmInfo[i].SubScripts[0]=-1; 1164 1165 psi->RealParmNum++; 1181 string name = pSub->name; 1182 if(pSub->name[0]==1&&pSub->name[1]==ESC_OPERATOR){ 1183 name="_System_ReturnValue"; 1184 } 1185 Type type( DEF_STRUCT, pSub->u.ReturnIndex ); 1186 pSub->realParams.push_back( new Parameter( name, type, true ) ); 1166 1187 } 1167 1188 1168 1189 //パラメータをコピー 1169 for ( i = 0; i < psi->ParmNum; i++, psi->RealParmNum++){1170 p si->pRealParmInfo[psi->RealParmNum]=psi->pParmInfo[i];1190 foreach( Parameter *pParam, pSub->params ){ 1191 pSub->realParams.push_back( new Parameter( *pParam ) ); 1171 1192 } 1172 1193 … … 1177 1198 1178 1199 int key; 1179 key=hash_default(p si->name);1180 1181 extern S UBINFO**ppSubHash;1200 key=hash_default(pSub->name); 1201 1202 extern SubInfo **ppSubHash; 1182 1203 if(ppSubHash[key]){ 1183 S UBINFO*psi2;1204 SubInfo *psi2; 1184 1205 psi2=ppSubHash[key]; 1185 1206 while(1){ 1186 1207 if(pobj_c==psi2->pobj_ParentClass){ 1187 1208 //重複エラーチェックを行う 1188 if(lstrcmp(psi2->name,p si->name)==0){1189 if( CompareParameter(psi2->pParmInfo,psi2->ParmNum,psi->pParmInfo,psi->ParmNum)==0){1190 SetError(15,p si->name,NowLine);1209 if(lstrcmp(psi2->name,pSub->name)==0){ 1210 if( Parameter::Equals( psi2->params, pSub->params ) ){ 1211 SetError(15,pSub->name,NowLine); 1191 1212 return 0; 1192 1213 } … … 1197 1218 psi2=psi2->pNextData; 1198 1219 } 1199 psi2->pNextData=p si;1220 psi2->pNextData=pSub; 1200 1221 } 1201 1222 else{ 1202 ppSubHash[key]=p si;1203 } 1204 1205 return p si;1223 ppSubHash[key]=pSub; 1224 } 1225 1226 return pSub; 1206 1227 } 1207 1228 … … 1217 1238 1218 1239 //サブルーチン(ユーザー定義)情報を初期化 1219 extern S UBINFO**ppSubHash;1240 extern SubInfo **ppSubHash; 1220 1241 extern int SubNum; 1221 ppSubHash=(S UBINFO **)HeapAlloc(hHeap,HEAP_ZERO_MEMORY,MAX_HASH*sizeof(SUBINFO*));1242 ppSubHash=(SubInfo **)HeapAlloc(hHeap,HEAP_ZERO_MEMORY,MAX_HASH*sizeof(SubInfo *)); 1222 1243 SubNum=0; 1223 1244 … … 1313 1334 AddSubData(temporary,0,0,0); 1314 1335 } 1315 void Delete_si(SUBINFO *psi){ 1316 int i2; 1317 1318 for(i2=0;i2<psi->ParmNum;i2++){ 1319 HeapDefaultFree(psi->pParmInfo[i2].name); 1320 } 1321 HeapDefaultFree(psi->pRealParmInfo); 1322 if(psi->pParmInfo) HeapDefaultFree(psi->pParmInfo); 1323 psi->pRealParmInfo=0; 1324 psi->pParmInfo=0; 1325 1326 if(psi->pNextData) Delete_si(psi->pNextData); 1327 1328 HeapDefaultFree(psi->name); 1329 HeapDefaultFree(psi); 1330 } 1331 void DeleteSubInfo(SUBINFO **ppSubHash,char **ppMacroNames,int MacroNum){ //サブルーチン情報のメモリ解放 1336 void Delete_si(SubInfo *pSub){ 1337 foreach( Parameter *pParam, pSub->params ){ 1338 delete pParam; 1339 } 1340 1341 foreach( Parameter *pParam, pSub->realParams ){ 1342 delete pParam; 1343 } 1344 1345 if(pSub->pNextData) Delete_si(pSub->pNextData); 1346 1347 HeapDefaultFree(pSub->name); 1348 delete pSub; 1349 } 1350 void DeleteSubInfo(SubInfo **ppSubHash,char **ppMacroNames,int MacroNum){ //サブルーチン情報のメモリ解放 1332 1351 int i; 1333 1352 for(i=0;i<MAX_HASH;i++){ -
BasicCompiler_Common/Type.cpp
r71 r73 108 108 return false; 109 109 } 110 111 112 bool Type::Equals( const Type &type ) const 113 { 114 if( basicType == type.basicType ){ 115 if( NATURAL_TYPE( basicType ) == DEF_OBJECT 116 || NATURAL_TYPE( basicType ) == DEF_STRUCT ){ 117 118 if( index == type.index ){ 119 return true; 120 } 121 122 } 123 else{ 124 return true; 125 } 126 } 127 return false; 128 } 129 130 bool Type::IsNull() const{ 131 if( basicType == DEF_NON ){ 132 return true; 133 } 134 return false; 135 } 136 bool Type::IsPointer() const 137 { 138 if(PTR_LEVEL( basicType )|| basicType == DEF_PTR_VOID || basicType == DEF_PTR_PROC 139 || ( basicType & FLAG_PTR ) ){ 140 return true; 141 } 142 143 return false; 144 } 145 bool Type::IsSigned() const 146 { 147 switch( basicType ){ 148 case DEF_SBYTE: 149 case DEF_INTEGER: 150 case DEF_LONG: 151 case DEF_INT64: 152 case DEF_SINGLE: 153 case DEF_DOUBLE: 154 return true; 155 default: 156 break; 157 } 158 return false; 159 } 160 bool Type::IsNaturalWhole() const 161 { 162 switch( basicType ){ 163 case DEF_SBYTE: 164 case DEF_BYTE: 165 case DEF_INTEGER: 166 case DEF_WORD: 167 case DEF_LONG: 168 case DEF_DWORD: 169 case DEF_INT64: 170 case DEF_QWORD: 171 return true; 172 default: 173 break; 174 } 175 return false; 176 } 177 bool Type::IsWhole() const 178 { 179 return ( 180 IsNaturalWhole() 181 || IsPtrType( basicType ) 182 || basicType == DEF_BOOLEAN 183 ); 184 } 185 bool Type::IsReal() const 186 { 187 switch( basicType ){ 188 case DEF_SINGLE: 189 case DEF_DOUBLE: 190 return true; 191 default: 192 break; 193 } 194 return false; 195 } 196 bool Type::Is64() const 197 { 198 switch( basicType ){ 199 case DEF_QWORD: 200 case DEF_INT64: 201 return true; 202 default: 203 break; 204 } 205 return false; 206 } 207 bool Type::IsProcPtr() const 208 { 209 if( basicType == DEF_PTR_PROC ){ 210 return true; 211 } 212 return false; 213 } 214 bool Type::IsStruct() const 215 { 216 if( basicType == DEF_STRUCT ){ 217 return true; 218 } 219 return false; 220 } -
BasicCompiler_Common/Type.h
r71 r73 4 4 5 5 class Type{ 6 static const int basicTypeList[]; 7 static const string basicTypeNameList[]; 8 9 6 10 int basicType; 7 11 union{ … … 10 14 }; 11 15 12 static const int basicTypeList[];13 static const string basicTypeNameList[];14 15 16 public: 16 17 18 static bool StringToBasicType( const string &typeName, int &basicType ); 19 static bool StringToType( const string &typeName, Type &type ); 20 21 Type(): 22 basicType( DEF_NON ), 23 index( -1 ){} 17 24 Type( int basicType ): 18 25 basicType( basicType ), … … 31 38 index( type.index ){} 32 39 33 int BasicType() const40 int GetBasicType() const 34 41 { 42 #ifdef _DEBUG 43 if( basicType<-10000 ){ 44 DebugBreak(); 45 } 46 #endif 35 47 return basicType; 36 48 } … … 44 56 } 45 57 58 void SetBasicType( int basicType ){ 59 this->basicType = basicType; 60 } 61 void SetIndex( LONG_PTR index ){ 62 this->index = index; 63 } 64 void SetNull(){ 65 SetBasicType( DEF_NON ); 66 } 67 void SetType( int basicType, LONG_PTR index ){ 68 SetBasicType( basicType ); 69 SetIndex( index ); 70 } 71 void SetType( int basicType, CClass *pClass ){ 72 SetBasicType( basicType ); 73 this->pClass = pClass; 74 } 75 46 76 void PtrLevelUp(){ 47 77 PTR_LEVEL_UP( basicType ); 48 78 } 49 79 50 bool Equals( const Type &type ) const 51 { 52 if( basicType == type.basicType ){ 53 if( NATURAL_TYPE( basicType ) == DEF_OBJECT 54 || NATURAL_TYPE( basicType ) == DEF_STRUCT ){ 80 bool Equals( const Type &type ) const; 55 81 56 if( index == type.index ){ 57 return true; 58 } 82 bool IsNull() const; 83 bool IsPointer() const; 84 bool IsSigned() const; 85 bool IsNaturalWhole() const; 86 bool IsWhole() const; 87 bool IsReal() const; 88 bool Is64() const; 89 bool IsProcPtr() const; 90 bool IsStruct() const; 59 91 60 }61 else{62 return true;63 }64 }65 return false;66 }67 68 bool IsPointer() const69 {70 if(PTR_LEVEL( basicType )|| basicType == DEF_PTR_VOID || basicType == DEF_PTR_PROC71 || ( basicType & FLAG_PTR ) ){72 return true;73 }74 75 return false;76 }77 78 79 80 static bool StringToBasicType( const string &typeName, int &basicType );81 static bool StringToType( const string &typeName, Type &type );82 92 }; 83 93 -
BasicCompiler_Common/Variable.cpp
r68 r73 819 819 820 820 char temporary[VN_SIZE]; 821 extern S UBINFO*pCompilingSubInfo;821 extern SubInfo *pCompilingSubInfo; 822 822 if(pCompilingSubInfo){ 823 823 GetNowStaticVarFullName(VarName,temporary); … … 1100 1100 //初期値の型を判別して自動的に型情報を付加する 1101 1101 TYPEINFO BaseType = GetStringTypeInfo(); 1102 int result = NumOpe_GetType ( InitBuf, &BaseType, &pTypeInfo->u.lpIndex );1102 int result = NumOpe_GetType_Old( InitBuf, &BaseType, &pTypeInfo->u.lpIndex ); 1103 1103 1104 1104 //エラーの場合 … … 1130 1130 1131 1131 BOOL GetNowStaticVarFullName(char *VarName,char *FullName){ 1132 extern S UBINFO*pCompilingSubInfo;1132 extern SubInfo *pCompilingSubInfo; 1133 1133 if(!pCompilingSubInfo) return 0; 1134 1134 -
BasicCompiler_Common/calculation.cpp
r69 r73 1195 1195 return 0; 1196 1196 } 1197 BOOL IsStringSubsituation(CClass *pobj_c){1198 //String受け入れ可能な "=" 演算子をオーバーロードしているかどうかを調べる1199 BOOL bRet=0;1200 1201 std::vector<SUBINFO *> subs;1202 pobj_c->EnumMethod( CALC_SUBSITUATION, subs );1203 if( subs.size() == 0 ){1204 bRet=0;1205 goto finish;1206 }1207 1208 foreach( SUBINFO *psi, subs ){1209 if(psi->ParmNum==2){1210 TYPEINFO TypeInfo={psi->pParmInfo[1].type,psi->pParmInfo[1].u.index};1211 if(IsStringObjectType( TypeInfo )){1212 bRet=1;1213 goto finish;1214 }1215 }1216 }1217 1218 finish:1219 return bRet;1220 }1221 1197 int IsStrCalculation(char *Command){ 1222 1198 int i,i2,i3,i4,type,PareNum; … … 1282 1258 1283 1259 //ユーザー定義関数 1284 S UBINFO*psi;1260 SubInfo *psi; 1285 1261 psi=GetSubHash(temporary); 1286 1262 if(psi){ -
BasicCompiler_Common/common.h
r71 r73 155 155 #include "Parameter.h" 156 156 157 // プロシージャ管理用のクラス 158 #include "Procedure.h" 159 157 160 158 161 … … 229 232 }; 230 233 231 #define SUBTYPE_SUB 1232 #define SUBTYPE_FUNCTION 2233 #define SUBTYPE_MACRO 3234 struct SUBINFO{235 DWORD dwType;236 237 //クラス情報238 CClass *pobj_ParentClass;239 240 long id;241 242 char *name;243 long address;244 245 //パラメータ246 PARAMETER_INFO *pParmInfo;247 int ParmNum;248 int SecondParmNum;249 PARAMETER_INFO *pRealParmInfo;250 int RealParmNum;251 int RealSecondParmNum;252 253 /*254 //パラメータ255 Parameters params;256 int SecondParmNum;257 Parameters realParams;258 int RealSecondParmNum;*/259 260 //戻り値261 int ReturnType;262 union{263 LONG_PTR ReturnIndex;264 CClass *Return_pobj_c;265 }u;266 bool isReturnRef;267 268 DWORD CompileAddress;269 DWORD EndOpAddr;270 VARIABLE *pVar;271 int VarNum;272 273 BOOL bExport;274 BOOL bCdecl;275 BOOL bVirtual;276 BOOL bUse;277 BOOL bCompile;278 BOOL bSystem;279 280 SUBINFO *pNextData;281 };282 234 #define DECLARE_DYNAMIC 1 283 235 #define DECLARE_STATIC 2 … … 435 387 CONSTINFO *GetConstHash(char *name); 436 388 DECLAREINFO *GetDeclareHash(char *name); 437 S UBINFO*GetSubHash(const char *name,BOOL bError=0);438 S UBINFO*GetMethodHash(char *ObjectName,char *MethodName,char *Parameter,BOOL bError=0);439 void GetOverloadSubHash( const char *lpszName, std::vector<S UBINFO*> &subs );389 SubInfo *GetSubHash(const char *name,BOOL bError=0); 390 SubInfo *GetMethodHash(char *ObjectName,char *MethodName,char *Parameter,BOOL bError=0); 391 void GetOverloadSubHash( const char *lpszName, std::vector<SubInfo *> &subs ); 440 392 441 393 //Object.cpp … … 444 396 445 397 //Overload.sbp 446 S UBINFO*OverloadSolutionWithStrParam(398 SubInfo *OverloadSolutionWithStrParam( 447 399 const char *name, 448 std::vector<S UBINFO*> &subs,400 std::vector<SubInfo *> &subs, 449 401 const char *Parameter, 450 402 const char *ObjectName, 451 403 TYPEINFO *pReturnTypeInfo); 452 S UBINFO*OverloadSolution(404 SubInfo *OverloadSolution( 453 405 const char *name, 454 std::vector<S UBINFO*> &subs,406 std::vector<SubInfo *> &subs, 455 407 const PARAMETER_INFO *ppi, 456 408 const int ParmNum, … … 464 416 void Debugger_Pause(void); 465 417 ULONG_PTR rva_to_real(DWORD p); 466 S UBINFO*GetSubFromObp(ULONG_PTR pos);418 SubInfo *GetSubFromObp(ULONG_PTR pos); 467 419 void ReadOpBuffer(); 468 420 void DebugProgram(void); … … 561 513 DWORD GetConstValue(char *name,double *dbl,char *buffer,LONG_PTR *plpIndex); 562 514 bool IsStringObjectType(const TYPEINFO &TypeInfo); 563 BOOL IsStringSubsituation(CClass *pobj_c);564 515 int IsStrCalculation(char *Command); 565 516 BYTE GetCalcId(const char *Command,int *pi); … … 567 518 char *values[255],long calc[255],long stack[255]); 568 519 569 //NumOpe_GetType .cpp520 //NumOpe_GetType_Old.cpp 570 521 int AutoBigCast(int BaseType,int CalcType); 571 522 BOOL CheckCalcType(int idCalc,int *type,int sp); 572 int NumOpe_GetType(char *Command,TYPEINFO *pBaseType,LONG_PTR *plpIndex); 523 int NumOpe_GetType_Old( const char *Command, TYPEINFO *pBaseTypeInfo, LONG_PTR *plpIndex ); 524 bool NumOpe_GetType( const char *expression, const Type &baseType, Type &resultType ); 573 525 574 526 //Subroutine.cpp … … 583 535 bool GetReturnTypeOfIndexerGetterProc(CClass *pobj_Class,TYPEINFO &RetTypeInfo); 584 536 BOOL CompareParameter(PARAMETER_INFO *ppi1,int pi_num1,PARAMETER_INFO *ppi2,int pi_num2); 585 S UBINFO*AddSubData(char *buffer,int NowLine,BOOL bVirtual,CClass *pobj_c,BOOL bStatic=0);537 SubInfo *AddSubData(char *buffer,int NowLine,BOOL bVirtual,CClass *pobj_c,BOOL bStatic=0); 586 538 void GetSubInfo(void); 587 void DeleteSubInfo(S UBINFO**ppSubHash,char **ppMacroNames,int MacroNum);539 void DeleteSubInfo(SubInfo **ppSubHash,char **ppMacroNames,int MacroNum); 588 540 void DeleteDeclareInfo(void); 589 541 int AddProcPtrInfo(char *buffer,DWORD dwProcType); -
BasicCompiler_Common/hash.cpp
r51 r73 53 53 } 54 54 55 void GetOverloadSubHash( const char *lpszName, std::vector<SUBINFO *> &subs ){ 56 extern SUBINFO *pSubInfo; 57 extern int SubInfoNum; 58 extern int cp; 59 55 void GetOverloadSubHash( const char *lpszName, std::vector<SubInfo *> &subs ){ 60 56 char name[VN_SIZE]; 61 57 … … 127 123 128 124 //格納位置を取得 129 extern S UBINFO**ppSubHash;130 S UBINFO*psi;125 extern SubInfo **ppSubHash; 126 SubInfo *psi; 131 127 psi=ppSubHash[key]; 132 128 while(psi){ … … 144 140 145 141 //オーバーロードされていない関数を取得(昔のコンパイラソースコードとの互換性保持) 146 S UBINFO*GetSubHash(const char *lpszName,BOOL bError){147 std::vector<S UBINFO*> subs;142 SubInfo *GetSubHash(const char *lpszName,BOOL bError){ 143 std::vector<SubInfo *> subs; 148 144 GetOverloadSubHash(lpszName,subs); 149 145 … … 158 154 } 159 155 160 S UBINFO*psi;156 SubInfo *psi; 161 157 psi = subs[0]; 162 158 163 159 return psi; 164 160 } 165 S UBINFO*GetMethodHash(char *ObjectName,char *MethodName,char *Parameter,BOOL bError){161 SubInfo *GetMethodHash(char *ObjectName,char *MethodName,char *Parameter,BOOL bError){ 166 162 char temporary[VN_SIZE]; 167 163 sprintf(temporary,"%s.%s",ObjectName,MethodName); 168 164 169 std::vector<S UBINFO*> subs;170 S UBINFO*psi;165 std::vector<SubInfo *> subs; 166 SubInfo *psi; 171 167 GetOverloadSubHash(temporary,subs); 172 168
Note:
See TracChangeset
for help on using the changeset viewer.