Changeset 290 in dev for trunk/abdev/BasicCompiler32/Compile_Var.cpp
- Timestamp:
- Aug 21, 2007, 11:00:25 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/abdev/BasicCompiler32/Compile_Var.cpp
r288 r290 160 160 return 1; 161 161 } 162 bool _member_offset(bool isErrorEnabled, bool isWriteAccess, const CClass &objClass, const char *member, RELATIVE_VAR *pRelativeVar, Type &resultType, BOOL bPrivateAccess){ 162 bool _member_offset(bool isErrorEnabled, bool isWriteAccess, const Type &classType, const char *member, RELATIVE_VAR *pRelativeVar, Type &resultType, BOOL bPrivateAccess) 163 { 164 const CClass &objClass = classType.GetClass(); 163 165 164 166 ////////////////////////////////////// … … 221 223 resultType = pMember->GetType(); 222 224 225 226 ///////////////////////////////////////////////////////// 227 // ☆★☆ ジェネリクスサポート ☆★☆ 228 229 if( resultType.IsTypeParameter() ) 230 { 231 // 型パラメータだったとき 232 if( classType.HasActualGenericType() ) 233 { 234 // TODO: GetDummyActualGenericTypeを適切な形に実装し直す 235 resultType = classType.GetDummyActualGenericType(); 236 } 237 else 238 { 239 // TODO: ベースオブジェクト(指定されていないときはObjectクラス)にセットする 240 resultType.SetBasicType( DEF_OBJECT ); 241 } 242 } 243 244 // 245 ///////////////////////////////////////////////////////// 246 247 223 248 //ポインタ変数の場合 224 249 if( resultType.IsPointer() ){ … … 321 346 isErrorEnabled, 322 347 isWriteAccess, 323 pMember->GetType() .GetClass(),348 pMember->GetType(), 324 349 NestMember, 325 350 pRelativeVar, … … 345 370 RelativeVar.offset=-LocalVar_ThisPtrOffset; 346 371 347 SetReg_WholeVariable( DEF_PTR_VOID,&RelativeVar,reg);372 SetReg_WholeVariable(Type(DEF_PTR_VOID),&RelativeVar,reg); 348 373 } 349 374 … … 472 497 isErrorEnabled, 473 498 isWriteAccess, 474 *compiler.pCompilingClass,499 Type( DEF_OBJECT, *compiler.pCompilingClass ), 475 500 variable, 476 501 pRelativeVar, … … 701 726 isErrorEnabled, 702 727 isWriteAccess, 703 resultType .GetClass(),728 resultType, 704 729 member,pRelativeVar,resultType,0)) return false; 705 730 … … 1204 1229 SetError(); 1205 1230 } 1206 SetVariableFromEax( DEF_OBJECT, DEF_OBJECT, &RelativeVar );1231 SetVariableFromEax( Type( DEF_OBJECT, *compiler.GetObjectModule().meta.GetClasses().GetObjectClassPtr() ), DEF_OBJECT, &RelativeVar ); 1207 1232 } 1208 1233 }
Note:
See TracChangeset
for help on using the changeset viewer.