ucx/map.h

changeset 209
4f02199d8aae
parent 208
262c7be94eba
child 225
a1a068c2c4ef
     1.1 --- a/ucx/map.h	Thu Oct 15 14:21:38 2015 +0200
     1.2 +++ b/ucx/map.h	Thu Oct 15 14:59:25 2015 +0200
     1.3 @@ -158,17 +158,19 @@
     1.4   * Frees the contents of a hash map.
     1.5   * 
     1.6   * This is a convenience function that iterates over the map and passes all
     1.7 - * values to the standard library free() function.
     1.8 + * values to the specified destructor function (e.g. stdlib free()).
     1.9   * 
    1.10 - * You must ensure, that it is valid to pass each value in the map to free().
    1.11 + * You must ensure, that it is valid to pass each value in the map to the same
    1.12 + * destructor function.
    1.13   * 
    1.14   * You should free or clear the map afterwards, as the contents will be invalid.
    1.15   * 
    1.16   * @param map for which the contents shall be freed
    1.17 + * @param destr pointer to the destructor function
    1.18   * @see ucx_map_free()
    1.19   * @see ucx_map_clear()
    1.20   */
    1.21 -void ucx_map_free_content(UcxMap *map);
    1.22 +void ucx_map_free_content(UcxMap *map, ucx_destructor destr);
    1.23  
    1.24  /**
    1.25   * Clears a hash map.

mercurial