www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 9915] New: Typeid .name inconsistent between templated classes and structs


           Summary: Typeid .name inconsistent between templated classes
                    and structs
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: callumenator gmail.com

--- Comment #0 from callumenator gmail.com 2013-04-09 20:13:09 PDT ---
DMD 2.062:

struct S(T){}
struct SS(T){}
struct SSS(T){}

class C(T){}
class CC(T){}
class CCC(T){}

void main()
    import std.stdio;
    writeln(typeid(S!(SS!(SSS!(int)))).name); // S!(SS!(SSS!(int))).S
    writeln(typeid(C!(CC!(CCC!(int)))).name); // C!(CC).C

It would be good to have the typeid().name field contain the full type name in
the case of templated classes, as it already does for templated structs.

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