www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 13404] New: heap-allocating a struct passes TypeInfo_Pointer

https://issues.dlang.org/show_bug.cgi?id=13404

          Issue ID: 13404
           Summary: heap-allocating a struct passes TypeInfo_Pointer to
                    the GC, not TypeInfo_struct
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P3
         Component: druntime
          Assignee: nobody puremagic.com
          Reporter: r.sagitario gmx.de

When allocating a struct instance with "new", the compiler generates a call to
_d_newitemT/_d_newitemiT, with the type info of the pointer to the struct as an
argument.

This type info is passed as is to the GC as a description, but should pass
ti.next.

--
Aug 30 2014