1. Unnamed mixin ---- import std.stdio; template Foo() { int x; } struct S { mixin Foo; } void main() { writefln(__traits(allMembers, S)); } ---- Outputs [__T3FooZ] instead of the expected [x] 2. Multiple unnamed mixins --- template Foo() { int x; } struct S { mixin Foo; mixin Foo; } void main() { writefln(__traits(allMembers, S)); } ---- Outputs [__T3FooZ]. What's the expected output anyway? Could the name conflict be detected before the conflicted name is referenced? 3. Template alias ---- import std.stdio; template Foo() { int x; } struct S { alias Foo!() foo; } void main() { writefln(__traits(allMembers, S)); } ---- Outputs [foo __T3FooZ] instead of the expected [foo]
Updating as this is still broken in 2.048
https://github.com/D-Programming-Language/dmd/pull/231
https://github.com/D-Programming-Language/dmd/commit/ddfeba9ced58881a343d8392a42f6910339c441c