How do I defeat the gratuitous qualification of alias members?
Chad Joan
chadjoan at gmail.com
Fri Apr 5 10:48:52 PDT 2013
On 04/05/2013 01:18 PM, Andrej Mitrovic wrote:
> On 4/5/13, Chad Joan<chadjoan at gmail.com> wrote:
>> Enums do not have instances.
>
> Sure they do.
>
> enum Foo
> {
> X,
> Y
> }
>
> void test(Foo foo) { }
>
> void main()
> {
> Foo foo = Foo.Y;
> test(foo);
> }
Where's the instance?
All I see is
void test(int foo) { }
void main()
{
int foo = 1;
test(foo);
}
There is no stateful aggregation for me to see here.
More information about the Digitalmars-d-learn
mailing list