[DGD]Sizeof arrays...

Felix A. Croes felix at dworkin.nl
Thu Jun 21 22:08:57 CEST 2001


"Michael J. Bacon" <mj.bacon at gte.net> wrote:

> 	When an array or mapping is passed to an extension is there an easy way to
> find out the max index, or number of key/value pairs?
>
> 	For example, when using the DGD_ARRAY_ELTS function on a mapping to return
> a pointer to an array of DGD_VALUE_Ts I need to know the upper bound of the
> array.

I'll add DGD_ARRAY_SIZE() and DGD_MAPPING_SIZE() to the interface.  For
now, use array->size and map_size(mapping).

Regards,
Dworkin

List config page:  http://list.imaginary.com/mailman/listinfo/dgd



More information about the DGD mailing list