Eneboo - Documentación para desarrolladores
|
Convenient wrappers that let us new up & delete objects from heaps. Más...
#include <new.h>
Ir al código fuente de este archivo.
Clases | |
class | newObject |
class | deleteObject |
class | newArray |
class | deleteArray |
Convenient wrappers that let us new up & delete objects from heaps.
Example:
Heap h;
Foo * foo;
newObject (foo,h); // instead of: foo = new Foo;
deleteObject (foo,h); // instead of: delete foo;
Foo * foo2;
newArray (foo2, 10, h); // instead of: foo2 = new Foo[10];
deleteArray (foo2, h); // instead of: delete [] foo2;