Next: , Previous: , Up: CType   [Index]


1.52.5 CType: C instance creation

address: cObjOrInt

Create a new CObject with the type (class) identified by the receiver, pointing to the given address (identified by an Integer or CObject).

gcNew

Allocate a new CObject with the type (class) identified by the receiver. The object is movable in memory, but on the other hand it is garbage-collected automatically.

gcNew: anInteger

Allocate a new CObject with room for anInteger C object of the type (class) identified by the receiver. The object is movable in memory, but on the other hand it is garbage-collected automatically.

new

Allocate a new CObject with the type (class) identified by the receiver. It is the caller’s responsibility to free the memory allocated for it.