GC.calloc

Sean Kelly sean at invisibleduck.org
Wed Jul 17 13:15:59 PDT 2013


On Jul 17, 2013, at 11:00 AM, David <d at dav1d.de> wrote:

> Why doesn't GC.calloc follow the function signature of stdc.calloc?
> 
> calloc(num, size_per_element)
> 
> I think this should be changed, if no reason speaks against it, I can
> look into changing this.
> Of course this will break backwards compatability, but I think this is
> worth it?

I sent a proposal to the runtime list ages ago about revamping the GC API.  But really, I'd like to eliminate GC.calloc entirely.  I'd rather have an allocation routine that takes a TypeInfo and uses that to initialize the block rather than just doing a memset(0) as per calloc.


More information about the Digitalmars-d mailing list