GC.calloc(), then what?
Ali Çehreli via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Fri Jun 27 00:03:27 PDT 2014
1) After allocating memory by GC.calloc() to place objects on it, what
else should one do? In what situations does one need to call addRoot()
or addRange()?
2) Does the answer to the previous question differ for struct objects
versus class objects?
3) Is there a difference between core.stdc.stdlib.calloc() and
GC.calloc() in that regard? Which one to use in what situation?
4) Are the random bit patterns in a malloc()'ed memory always a concern
for false pointers? Does that become a concern after calling addRoot()
or addRange()? If so, why would anyone ever malloc() instead of always
calloc()'ing?
Ali
More information about the Digitalmars-d-learn
mailing list