[Issue 1677] New: Segfault on specialization on template with one non-tuple and one tuple parameter
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sat Nov 17 08:34:13 PST 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1677
Summary: Segfault on specialization on template with one non-
tuple and one tuple parameter
Product: D
Version: 1.023
Platform: PC
OS/Version: Windows
Status: NEW
Severity: normal
Priority: P2
Component: DMD
AssignedTo: bugzilla at digitalmars.com
ReportedBy: jarrett.billingsley at gmail.com
struct Temp(T, U...)
{
}
void foo(T : Temp!(U, V), U, V)(T t)
{
}
void main()
{
Temp!(float, float, char) y;
foo!(typeof(y))(y);
}
Interesting things:
- Using "Temp!(float, float) y" instead works.
- Using a specialization with three inferred parameters instead of two ("T :
Temp!(U, V, W), U, V, W") works.
- Using a specialization with one inferred parameter causes a compilation
error.
- Changing the template Temp to take only a tuple parameter (remove T) causes
compilation errors.
I don't know whether to flag this as 'ice-on-invalid-code' or
'ice-on-valid-code' because I don't even know if this code is valid.
--
More information about the Digitalmars-d-bugs
mailing list