xxxxxxxxxx
struct S
{
int count;
}
void write(alias Var, string field)()
{
import std;
writefln(
"%s.%s = %s",
__traits(identifier, Var),
field,
mixin("Var."~field)
);
}
void main()
{
S s = S(200);
write!(s, "count");
}