import std.stdio;
import std.string;
template Foo(string Head)
{
mixin("int " ~ Head ~ ";");
}
template Foo(string Head, Tail...)
{
mixin Foo!Head;
mixin Foo!Tail;
}
struct Bar(Params...)
{
mixin Foo!Params;
}
void main()
{
Bar!("hello", "world") bar;
bar.hello = 10;
bar.world = 20;
writeln(bar.hello, " ", bar.world);
}
aW1wb3J0IHN0ZC5zdGRpbzsKaW1wb3J0IHN0ZC5zdHJpbmc7Cgp0ZW1wbGF0ZSBGb28oc3RyaW5nIEhlYWQpCnsKICAgIG1peGluKCJpbnQgIiB+IEhlYWQgfiAiOyIpOwp9Cgp0ZW1wbGF0ZSBGb28oc3RyaW5nIEhlYWQsIFRhaWwuLi4pCnsKICAgIG1peGluIEZvbyFIZWFkOwogICAgbWl4aW4gRm9vIVRhaWw7Cn0KCnN0cnVjdCBCYXIoUGFyYW1zLi4uKQp7CiAgICBtaXhpbiBGb28hUGFyYW1zOwp9Cgp2b2lkIG1haW4oKQp7CiAgICBCYXIhKCJoZWxsbyIsICJ3b3JsZCIpIGJhcjsKICAgIGJhci5oZWxsbyA9IDEwOwogICAgYmFyLndvcmxkID0gMjA7CiAgICB3cml0ZWxuKGJhci5oZWxsbywgIiAiLCBiYXIud29ybGQpOwp9Cg==