[Issue 13252] New: ParameterDefaultValueTuple affects other instantiations
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Mon Aug 4 01:36:56 PDT 2014
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: nobody at puremagic.com
Reporter: thecybershadow at gmail.com
/////////////////////////////////// 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
--
More information about the Digitalmars-d-bugs
mailing list