Changeset 137 in dev for BasicCompiler32
- Timestamp:
- Jun 8, 2007, 3:11:47 AM (17 years ago)
- Location:
- BasicCompiler32
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
BasicCompiler32/Compile_CallProc.cpp
r135 r137 170 170 // アクセスエラーチェック 171 171 ////////////////////////////// 172 DWORD dwAccess = pMethod->dwAccess;173 172 174 173 if(ObjectName[0]){ … … 176 175 if(pobj_c==pobj_CompilingClass){ 177 176 //同一クラスオブジェクトの場合はプライベートアクセスを容認する 178 if( dwAccess==ACCESS_NON){177 if( pMethod->IsNoneAccess() ){ 179 178 SetError(109,pUserProc->GetName(),cp); 180 179 return false; … … 182 181 } 183 182 else{ 184 if( dwAccess==ACCESS_PRIVATE||185 dwAccess==ACCESS_NON){183 if( pMethod->IsPrivate() 184 || pMethod->IsNoneAccess() ){ 186 185 SetError(109,pUserProc->GetName(),cp); 187 186 return false; 188 187 } 189 if( dwAccess==ACCESS_PROTECTED){188 if( pMethod->IsProtected() ){ 190 189 SetError(110,pUserProc->GetName(),cp); 191 190 return false; … … 195 194 else{ 196 195 //クラス内部からの呼び出し(継承によるACCESS_NONのみをエラーとする) 197 if( dwAccess==ACCESS_NON){196 if( pMethod->IsNoneAccess() ){ 198 197 SetError(109,pUserProc->GetName(),cp); 199 198 return false; -
BasicCompiler32/Compile_Var.cpp
r135 r137 190 190 if(&objClass==pobj_CompilingClass){ 191 191 //同一クラスオブジェクトの場合はプライベートアクセスを容認する 192 if(pMember-> dwAccess==ACCESS_NON){192 if(pMember->IsNoneAccess()){ 193 193 if(isErrorEnabled) SetError(107,VarName,cp); 194 194 return false; … … 196 196 } 197 197 else{ 198 if((bPrivateAccess==0&&pMember-> dwAccess==ACCESS_PRIVATE)||199 pMember-> dwAccess==ACCESS_NON){198 if((bPrivateAccess==0&&pMember->IsPrivate())|| 199 pMember->IsNoneAccess()){ 200 200 if(isErrorEnabled) SetError(107,VarName,cp); 201 201 return false; 202 202 } 203 else if(bPrivateAccess==0&&pMember-> dwAccess==ACCESS_PROTECTED){203 else if(bPrivateAccess==0&&pMember->IsProtected()){ 204 204 if(isErrorEnabled) SetError(108,VarName,cp); 205 205 return false; … … 217 217 } 218 218 219 resultType = *pMember;219 resultType = pMember->GetType(); 220 220 221 221 //ポインタ変数の場合 … … 243 243 if(array[0]){ 244 244 //配列オフセット 245 if(!GetArrayOffset(pMember->SubScripts,array, *pMember)){245 if(!GetArrayOffset(pMember->SubScripts,array,pMember->GetType())){ 246 246 if(isErrorEnabled) SetError(14,member,cp); 247 247 } … … 323 323 isErrorEnabled, 324 324 isWriteAccess, 325 pMember->Get Class(),325 pMember->GetType().GetClass(), 326 326 NestMember, 327 327 pRelativeVar, … … 755 755 756 756 if(!SetInitGlobalData(offset+i3, 757 *objClass.ppobj_Member[i2],757 objClass.ppobj_Member[i2]->GetType(), 758 758 objClass.ppobj_Member[i2]->SubScripts, 759 759 temporary)) return false; … … 891 891 892 892 if(!InitLocalVar(offset+i3, 893 *objClass.ppobj_Member[i2],893 objClass.ppobj_Member[i2]->GetType(), 894 894 objClass.ppobj_Member[i2]->SubScripts, 895 895 temporary)) return false;
Note:
See TracChangeset
for help on using the changeset viewer.