From b80cbad1cc11ca93375076568cbd07c9f3de0697 Mon Sep 17 00:00:00 2001 From: k-hara Date: Sat, 6 Apr 2013 03:23:19 +0900 Subject: [PATCH] fix Issue 9431 - Tuple creation problem with array of array --- std/typecons.d | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/std/typecons.d b/std/typecons.d index d23b7a2670b..f74e598e409 100644 --- a/std/typecons.d +++ b/std/typecons.d @@ -412,8 +412,7 @@ writeln(t.expand); // 1 hello 2.3 Constructor taking one value for each field. Each argument must be implicitly assignable to the respective element of the target. */ - this(U...)(U values) - if (is(typeof({ void fun(Types); fun(values); }))) + this()(Types values) { foreach (i, _; Types) { @@ -739,6 +738,11 @@ unittest alias Tuple!(const(int)) T; auto t2 = T(1); } + // 9431 + { + alias T = Tuple!(int[1][]); + auto t = T([[10]]); + } } unittest {