Re: AliasSeq in UDA

2019-03-10 Thread Basile B. via Digitalmars-d-learn
On Sunday, 10 March 2019 at 17:04:20 UTC, Sebastiaan Koppe wrote: On Sunday, 10 March 2019 at 16:46:43 UTC, Basile B. wrote: Yes I see. I've refined a bit the test case and maybe I'll took a look this week. Cool. Is it normal to create a testcase that doesn't depend on phobos? I suppose it

Re: AliasSeq in UDA

2019-03-10 Thread Sebastiaan Koppe via Digitalmars-d-learn
On Sunday, 10 March 2019 at 16:46:43 UTC, Basile B. wrote: Yes I see. I've refined a bit the test case and maybe I'll took a look this week. Cool. Is it normal to create a testcase that doesn't depend on phobos? I suppose it is needed for it to be included in dmd's testcases.

Re: AliasSeq in UDA

2019-03-10 Thread Basile B. via Digitalmars-d-learn
On Sunday, 10 March 2019 at 16:05:19 UTC, Sebastiaan Koppe wrote: On Sunday, 10 March 2019 at 13:41:32 UTC, Basile B. wrote: It looks like a bug, a "reject-valid" one. Try the same code with enum A = 0; and it work, despite of B being still opaque. The problem may be related to the fact

Re: AliasSeq in UDA

2019-03-10 Thread Sebastiaan Koppe via Digitalmars-d-learn
On Sunday, 10 March 2019 at 13:41:32 UTC, Basile B. wrote: It looks like a bug, a "reject-valid" one. Try the same code with enum A = 0; and it work, despite of B being still opaque. The problem may be related to the fact the enum A in the orginal code is opaque and has not type.

Re: AliasSeq in UDA

2019-03-10 Thread Basile B. via Digitalmars-d-learn
On Sunday, 10 March 2019 at 13:20:12 UTC, Sebastiaan Koppe wrote: The compiler complains about `cannot form tuple of tuples` whenever I try to put an AliasSeq in a UDA and try to use it. You would expect the compiler to expand it. Is this a bug? --- import std.meta; enum A; enum B

Re: AliasSeq in UDA

2019-03-10 Thread Basile B. via Digitalmars-d-learn
On Sunday, 10 March 2019 at 13:41:32 UTC, Basile B. wrote: On Sunday, 10 March 2019 at 13:20:12 UTC, Sebastiaan Koppe wrote: The compiler complains about `cannot form tuple of tuples` whenever I try to put an AliasSeq in a UDA and try to use it. You would expect the compiler to expand

AliasSeq in UDA

2019-03-10 Thread Sebastiaan Koppe via Digitalmars-d-learn
The compiler complains about `cannot form tuple of tuples` whenever I try to put an AliasSeq in a UDA and try to use it. You would expect the compiler to expand it. Is this a bug? --- import std.meta; enum A; enum B; @AliasSeq!(A,B) // <-- Error: cannot form tuple of tuples struct