From 923a8237b64dca3a0ecebcfd69edec0627edacd9 Mon Sep 17 00:00:00 2001 From: Andrea Mazzoleni Date: Sun, 15 Dec 2013 10:56:26 +0100 Subject: [PATCH] Updates with latest TommyDS. --- tommyarrayblk.h | 2 +- tommyarrayblkof.h | 4 ++++ tommyhashdyn.h | 3 +++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/tommyarrayblk.h b/tommyarrayblk.h index 093ec6fb..5dd57047 100644 --- a/tommyarrayblk.h +++ b/tommyarrayblk.h @@ -34,7 +34,7 @@ * the already allocated memory, and then not increasing the heap fragmentation. * This means that the address of the allocated blocks never change. * - * Allocated blocks are always of the same fixed size of 64 KiB. + * Allocated blocks are always of the same fixed size of 64 Ki pointers. */ #ifndef __TOMMYARRAYBLK_H diff --git a/tommyarrayblkof.h b/tommyarrayblkof.h index 4b16b3b3..f3fa0c8a 100644 --- a/tommyarrayblkof.h +++ b/tommyarrayblkof.h @@ -32,6 +32,9 @@ * * This is very similar at ::tommy_arrayblk, but it allows to store elements of any * size and not just pointers. + * + * Note that in this case tommy_arrayblkof_ref() returns a pointer at the element, + * and it should be used for both get() and set() operation. */ #ifndef __TOMMYARRAYBLKOF_H @@ -61,6 +64,7 @@ typedef struct tommy_arrayblkof_struct { /** * Initializes the array. + * \param element_size Size in byte of the element to store in the array. */ void tommy_arrayblkof_init(tommy_arrayblkof* array, unsigned element_size); diff --git a/tommyhashdyn.h b/tommyhashdyn.h index 2c9047e4..f768e96c 100644 --- a/tommyhashdyn.h +++ b/tommyhashdyn.h @@ -170,6 +170,9 @@ void tommy_hashdyn_init(tommy_hashdyn* hashdyn); /** * Deinitializes the hashtable. + * + * You can call this function with elements still contained, + * but such elements are not going to be freed by this call. */ void tommy_hashdyn_done(tommy_hashdyn* hashdyn);