private IEnumerable <ICustomAttribute> WriteTypeDefinitionFieldsAsAttributes(TypeDefinition member) { V_0 = new List <ICustomAttribute>(); if (member.get_IsSerializable()) { V_0.Add(AttributesUtilities.GetTypeSerializableAttribute(member)); } if (member.get_IsExplicitLayout()) { V_0.Add(AttributesUtilities.GetTypeExplicitLayoutAttribute(member)); } return(V_0); }
private IEnumerable <ICustomAttribute> WriteTypeDefinitionFieldsAsAttributes(TypeDefinition member) { List <ICustomAttribute> attributes = new List <ICustomAttribute>(); //write [Serializable] attribute if (member.IsSerializable) { attributes.Add(AttributesUtilities.GetTypeSerializableAttribute(member)); } //write [StructLayout(LayoutKind.Explicit)] attribute if (member.IsExplicitLayout) { attributes.Add(AttributesUtilities.GetTypeExplicitLayoutAttribute(member)); } return(attributes); }