using System;
 
 enum Sexs
 {
  Male,
  Female
 };
    
 public class Person
 {  protected string name="siyixin";
  protected Sexs sex=Sexs.Male; //报错位置
 
  public virtual void getInfo()
  {
  Console.WriteLine("Name:{0}",name);
  Console.WriteLine("Sex: {0}",sex);
  Console.WriteLine("Enum Sexs: {0},{1}",Sexs.Male,Sexs.Female);
  }
 } public class Employee:Person
 {
  public string id="123456";
  public override void getInfo()
  {
  base.getInfo();
  Console.WriteLine("Id:  {0}",id);
  }
 }
 
 class TestClass
 {
  public static void Main()
  {
  Employee E=new Employee();
  E.getInfo();
  }
 }//报错提示:
//base1.cs(22,18): error CS0052: Inconsistent accessibility: field type 'Sexs' is
//        less accessible than field 'Person.sex'
//base1.cs(12,7): (Location of symbol related to previous error)