On 1/8/19 1:35 PM, Machine Code wrote:
I'm using enum to compute the value at runtime like this:
struct A
{
enum foo = A("foo", 10);
enum baa = A("baa", 20);
string name;
int value;
alias value this;
}
In order to avoid foo having its value (even if literal) copied eve
I'm using enum to compute the value at runtime like this:
struct A
{
enum foo = A("foo", 10);
enum baa = A("baa", 20);
string name;
int value;
alias value this;
}
In order to avoid foo having its value (even if literal) copied
every time A instancied and