[Issue 12292] New: Template specialization ": string" passes for static arrays of other types

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Mar 3 08:39:40 PST 2014


https://d.puremagic.com/issues/show_bug.cgi?id=12292

           Summary: Template specialization ": string" passes for static
                    arrays of other types
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: accepts-invalid
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: thecybershadow at gmail.com


--- Comment #0 from Vladimir Panteleev <thecybershadow at gmail.com> 2014-03-03 18:39:38 EET ---
////////// test.d //////////
void fun(T : string)(T data)
{
    string sdata = data;
}

void test()
{
    ubyte[3] sa;
    fun(sa);
}
////////////////////////////

The specialization passes, and then the assignment inside the function fails to
compile.

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list