This is similar to bug 6369, but different. template Seq(T...) { alias T Seq; } void main() { int x, y; Seq!(x, y) = tup(10, 20); assert(x == 10); assert(y == 20); }
Sorry, Comment#0's sample code is incomplete. template Seq(T...) { alias T Seq; } struct Tup(T...) { T field; alias field this; } void main() { int x, y; Seq!(x, y) = Tup!(int, int)(10, 20); assert(x == 10); assert(y == 20); }
https://github.com/D-Programming-Language/dmd/commit/61f993881637c59615cc00926b568e16bd573dce