I\'ve run into a really interesting runtime bug which generates a rogue stack overflow.
I\'ve defined a structure as follows:
public enum EnumDataTy
I don't understand how the first line: request.DataSize = 60;
Doesn't cause a stack overflow - my advice would be to use backing properties:
public class DataRequest
{
protected int dataSize = 0;
protected EnumDataType enumDataType;
public long DataSize { get { return 0; } set { dataSize = value; } }
public EnumDataType DataType { get { return EnumDataType.Apple; } set { enumDataType = value;}
}