Index: BasicCompiler_Common/Class.cpp
===================================================================
--- BasicCompiler_Common/Class.cpp	(revision 135)
+++ BasicCompiler_Common/Class.cpp	(revision 137)
@@ -165,8 +165,11 @@
 		ppobj_Member[iMemberNum]=new CMember( *inheritsClass.ppobj_Member[i3] );
 
-		//dwAccess
-		if(inheritsClass.ppobj_Member[i3]->dwAccess==ACCESS_PRIVATE)
-			ppobj_Member[iMemberNum]->dwAccess=ACCESS_NON;
-		else ppobj_Member[iMemberNum]->dwAccess=inheritsClass.ppobj_Member[i3]->dwAccess;
+		// アクセシビリティ
+		if( inheritsClass.ppobj_Member[i3]->IsPrivate() ){
+			ppobj_Member[iMemberNum]->SetAccessibility( Prototype::None );
+		}
+		else{
+			ppobj_Member[iMemberNum]->SetAccessibility( inheritsClass.ppobj_Member[i3]->GetAccessibility() );
+		}
 
 		iMemberNum++;
@@ -177,8 +180,11 @@
 		CMethod *pMethod = new DynamicMethod( *pBaseMethod );
 
-		//dwAccess
-		if(pBaseMethod->dwAccess==ACCESS_PRIVATE)
-			pMethod->dwAccess=ACCESS_NON;
-		else pMethod->dwAccess=pBaseMethod->dwAccess;
+		// アクセシビリティ
+		if(pBaseMethod->GetAccessibility() == Prototype::Private){
+			pMethod->SetAccessibility( Prototype::None );
+		}
+		else{
+			pMethod->SetAccessibility( pBaseMethod->GetAccessibility() );
+		}
 
 		//pobj_Inherits
@@ -221,8 +227,11 @@
 		CMethod *pMethod = new DynamicMethod( *pBaseMethod );
 
-		//dwAccess
-		if(pBaseMethod->dwAccess==ACCESS_PRIVATE)
-			pMethod->dwAccess=ACCESS_NON;
-		else pMethod->dwAccess=pBaseMethod->dwAccess;
+		// アクセシビリティ
+		if(pBaseMethod->GetAccessibility() == Prototype::Private){
+			pMethod->SetAccessibility( Prototype::None );
+		}
+		else{
+			pMethod->SetAccessibility( pBaseMethod->GetAccessibility() );
+		}
 
 		//pobj_Inherits
@@ -245,11 +254,11 @@
 	return true;
 }
-void CClass::AddMember( DWORD dwAccess, bool isConst, bool isRef, char *buffer ){
+void CClass::AddMember( Prototype::Accessibility accessibility, bool isConst, bool isRef, char *buffer ){
 	ppobj_Member = (CMember **)HeapReAlloc( hHeap, 0, ppobj_Member, ( iMemberNum + 1 ) * sizeof(CMember *) );
-	ppobj_Member[iMemberNum] = new CMember( this, dwAccess, isConst, isRef, buffer );
+	ppobj_Member[iMemberNum] = new CMember( this, accessibility, isConst, isRef, buffer );
 	iMemberNum++;
 }
-void CClass::AddStaticMember( DWORD dwAccess, bool isConst, bool isRef, char *buffer, int nowLine ){
-	CMember *member = new CMember( this, dwAccess, isConst, isRef, buffer, nowLine );
+void CClass::AddStaticMember( Prototype::Accessibility accessibility, bool isConst, bool isRef, char *buffer, int nowLine ){
+	CMember *member = new CMember( this, accessibility, isConst, isRef, buffer, nowLine );
 	staticMembers.push_back( member );
 }
@@ -326,11 +335,11 @@
 		CMember *pMember = ppobj_Member[i];
 
-		i2 = pMember->GetSize();
+		i2 = pMember->GetType().GetSize();
 
 		//アラインメントを算出
 		int member_size;
-		if( pMember->IsStruct() ){
+		if( pMember->GetType().IsStruct() ){
 			//メンバクラスのアラインメントを取得
-			member_size=pMember->GetClass().GetAlignment();
+			member_size=pMember->GetType().GetClass().GetAlignment();
 		}
 		else{
@@ -393,11 +402,11 @@
 		CMember *pMember = ppobj_Member[i];
 
-		if(pMember->IsStruct()){
+		if(pMember->GetType().IsStruct()){
 			//メンバクラスのアラインメントを取得
-			member_size=pMember->GetClass().GetAlignment();
+			member_size=pMember->GetType().GetClass().GetAlignment();
 		}
 		else{
 			//メンバサイズを取得
-			member_size = pMember->GetSize();
+			member_size = pMember->GetType().GetSize();
 		}
 
@@ -837,5 +846,5 @@
 
 
-void CDBClass::AddMethod(CClass *pobj_c, DWORD dwAccess, BOOL bStatic, bool isConst, bool isAbstract,
+void CDBClass::AddMethod(CClass *pobj_c, Prototype::Accessibility accessibility, BOOL bStatic, bool isConst, bool isAbstract,
 						 bool isVirtual, bool isOverride, char *buffer, int nowLine){
 	int i,i2;
@@ -932,5 +941,5 @@
 						SetError(127,NULL,nowLine);
 					}
-					if(pMethod->dwAccess!=dwAccess){
+					if(pMethod->GetAccessibility() != accessibility ){
 						SetError(128,NULL,nowLine);
 					}
@@ -952,8 +961,8 @@
 
 	if(bStatic){
-		pobj_c->staticMethods.AddStatic(pUserProc,dwAccess);
+		pobj_c->staticMethods.AddStatic( pUserProc, accessibility );
 	}
 	else{
-		pobj_c->methods.Add(pUserProc, dwAccess, isConst, isAbstract, isVirtual);
+		pobj_c->methods.Add(pUserProc, accessibility, isConst, isAbstract, isVirtual);
 	}
 }
@@ -963,9 +972,9 @@
 	for(i=0;i<objClass.iMemberNum;i++){
 		const CMember *pMember = objClass.ppobj_Member[i];
-		if(pMember->IsStruct()){
+		if(pMember->GetType().IsStruct()){
 			//循環参照でないかをチェック
-			if(pobj_LoopRefCheck->check(pMember->GetClass())){
+			if(pobj_LoopRefCheck->check(pMember->GetType().GetClass())){
 				extern int cp;
-				SetError(124,pMember->GetClass().GetName(),cp);
+				SetError(124,pMember->GetType().GetClass().GetName(),cp);
 				return 0;
 			}
@@ -973,5 +982,5 @@
 			pobj_LoopRefCheck->add(objClass.GetName().c_str());
 
-			i2=MemberVar_LoopRefCheck(pMember->GetClass());
+			i2=MemberVar_LoopRefCheck(pMember->GetType().GetClass());
 			if(bRet==1) bRet=i2;
 
@@ -986,5 +995,4 @@
 	extern char *basbuf;
 	int i,i2,i3,sub_address,top_pos;
-	DWORD dwAccess;
 	char temporary[8192];
 
@@ -1140,5 +1148,5 @@
 				//メンバ関数を追加
 				AddMethod(pobj_c,
-					ACCESS_PUBLIC,		//Publicアクセス権
+					Prototype::Public,	//Publicアクセス権
 					0,					//Static指定なし
 					false,				//Constではない
@@ -1212,6 +1220,11 @@
 
 			//アクセス制限の初期値をセット
-			if(dwClassType==ESC_CLASS) dwAccess=ACCESS_PRIVATE;
-			else dwAccess=ACCESS_PUBLIC;
+			Prototype::Accessibility accessibility;
+			if(dwClassType==ESC_CLASS){
+				accessibility = Prototype::Private;
+			}
+			else{
+				accessibility = Prototype::Public;
+			}
 
 			if( pobj_c->GetName() == "Object" || dwClassType == ESC_TYPE ){
@@ -1342,13 +1355,13 @@
 				//アクセスを変更
 				if(lstrcmpi(temporary,"Private")==0){
-					dwAccess=ACCESS_PRIVATE;
+					accessibility = Prototype::Private;
 					continue;
 				}
 				if(lstrcmpi(temporary,"Public")==0){
-					dwAccess=ACCESS_PUBLIC;
+					accessibility = Prototype::Public;
 					continue;
 				}
 				if(lstrcmpi(temporary,"Protected")==0){
-					dwAccess=ACCESS_PROTECTED;
+					accessibility = Prototype::Protected;
 					continue;
 				}
@@ -1359,26 +1372,26 @@
 						//静的メンバを追加
 						cp=i;	//エラー用
-						pobj_c->AddStaticMember( dwAccess, isConst, false, temporary, i);
+						pobj_c->AddStaticMember( accessibility, isConst, false, temporary, i);
 					}
 					else{
 						//メンバを追加
 						cp=i;	//エラー用
-						pobj_c->AddMember( dwAccess, isConst, false, temporary );
-
-
-						if(pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->IsStruct()){
-							if(pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->GetClass().ppobj_Member==0){
+						pobj_c->AddMember( accessibility, isConst, false, temporary );
+
+
+						if(pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->GetType().IsStruct()){
+							if(pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->GetType().GetClass().ppobj_Member==0){
 								//参照先が読み取られていないとき
-								GetClass_recur(pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->GetClass().GetName().c_str());
+								GetClass_recur(pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->GetType().GetClass().GetName().c_str());
 							}
 						}
 
 
-						if(pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->IsStruct()){
+						if(pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->GetType().IsStruct()){
 							//循環参照のチェック
 							pobj_LoopRefCheck->add(pobj_c->GetName().c_str());
-							if(!MemberVar_LoopRefCheck(pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->GetClass())){
+							if(!MemberVar_LoopRefCheck(pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->GetType().GetClass())){
 								//エラー回避
-								pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->SetBasicType( DEF_PTR_VOID );
+								pobj_c->ppobj_Member[pobj_c->iMemberNum-1]->GetType().SetBasicType( DEF_PTR_VOID );
 							}
 							pobj_LoopRefCheck->del(pobj_c->GetName().c_str());
@@ -1390,5 +1403,5 @@
 					cp=i;	//エラー用
 					AddMethod(pobj_c,
-						dwAccess,
+						accessibility,
 						bStatic,
 						isConst,
@@ -1466,5 +1479,5 @@
 			CMember &member = *objClass.ppobj_Member[i];
 
-			if( member.IsObject() || member.IsPointer() ){
+			if( member.GetType().IsObject() || member.GetType().IsPointer() ){
 				if( referenceOffsetsBuffer[0] ){
 					lstrcat( referenceOffsetsBuffer, "," );
