bool CheckBaseFieldOrProperty (string id, Type type, ref MemberAttributes ma)
{
FieldInfo fld = parser.BaseType.GetField (id, noCaseFlags);
Type other = null;
if (fld == null || fld.IsPrivate) {
PropertyInfo prop = parser.BaseType.GetProperty (id, noCaseFlags);
if (prop != null) {
MethodInfo setm = prop.GetSetMethod (true);
if (setm != null)
other = prop.PropertyType;
}
} else {
other = fld.FieldType;
}
if (other == null)
return false;
if (!other.IsAssignableFrom (type)) {
ma |= MemberAttributes.New;
return false;
}
return true;
}