void GB.NewArray ( void * parray , long size , long count )
Creates a new array.
void *
pointer, but a TYPE **
pointer casted to void *
, TYPE
being
the type of the data that will be stored in the array.
sizeof(TYPE)
.
Be careful ! Don't mistake this function for GB.Array.New, that creates Gambas array objects.
Example :
/* Creates an array of integers with n slots */ int *array; GB.NewArray((void *)&array, sizeof(*array), n);