From: Arnaud Giersch Date: Mon, 28 Nov 2011 12:50:46 +0000 (+0100) Subject: Add two fields to struct dict, in prevision of homogeneous dicts. X-Git-Tag: exp_20120216~241^2~21 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/25d5daee59894589a8454b998c85202c71b01305 Add two fields to struct dict, in prevision of homogeneous dicts. --- diff --git a/src/xbt/dict.c b/src/xbt/dict.c index d4ed6ce906..4ec20c9d4e 100644 --- a/src/xbt/dict.c +++ b/src/xbt/dict.c @@ -32,10 +32,12 @@ xbt_dict_t xbt_dict_new(void) xbt_dict_t dict; dict = xbt_new(s_xbt_dict_t, 1); + dict->free_f = NULL; dict->table_size = 127; dict->table = xbt_new0(xbt_dictelm_t, dict->table_size + 1); dict->count = 0; dict->fill = 0; + dict->homogeneous = 0; return dict; } diff --git a/src/xbt/dict_private.h b/src/xbt/dict_private.h index b403501870..c25f8d939f 100644 --- a/src/xbt/dict_private.h +++ b/src/xbt/dict_private.h @@ -33,10 +33,12 @@ typedef struct s_xbt_dictelm { } s_xbt_dictelm_t; typedef struct s_xbt_dict { + void_f_pvoid_t free_f; xbt_dictelm_t *table; int table_size; int count; int fill; + int homogeneous; } s_xbt_dict_t; typedef struct s_xbt_dict_cursor s_xbt_dict_cursor_t;