https://issues.dlang.org/show_bug.cgi?id=13252
Issue ID: 13252
Summary: ParameterDefaultValueTuple affects other
instantiations
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Keywords: rejects-valid
Severity: regression
Priority: P1
Component: DMD
Assignee: [email protected]
Reporter: [email protected]
/////////////////////////////////// test.d ///////////////////////////////////
import std.traits;
void f1(string[] = null) {}
void f2(string = null) {}
static assert(is(typeof(ParameterDefaultValueTuple!f1[0]) == string[])); // OK
static assert(is(typeof(ParameterDefaultValueTuple!f2[0]) == string )); // NG
//////////////////////////////////////////////////////////////////////////////
The second assert fails. If the first assert is commented out, the second
assert passes.
This worked in DMD 2.060 and no longer works since DMD 2.061.
Introduced in https://github.com/D-Programming-Language/dmd/pull/1368
--