Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Current state. See changelog, sorry, I'm out of time
[simgrid.git] / include / xbt / set.h
index efe493b..5ab5d1c 100644 (file)
@@ -26,13 +26,13 @@ typedef struct gras_set_elm_ {
 
 /*####[ Functions ]##########################################################*/
 
-gras_error_t gras_set_new (gras_set_t **dst);
-void         gras_set_free(gras_set_t **set);
+gras_set_t *gras_set_new (void);
+void gras_set_free(gras_set_t **set);
 
 
-gras_error_t gras_set_add    (gras_set_t     *set,
-                             gras_set_elm_t *elm,
-                             void_f_pvoid_t *free_func);
+void gras_set_add (gras_set_t     *set,
+                  gras_set_elm_t *elm,
+                  void_f_pvoid_t *free_func);
 
 /*----[ gras_set_retrieve ]-------------------------------------------------*/
 /* Search the given #key#. data=NULL when not found.                         */
@@ -61,7 +61,7 @@ int          gras_set_cursor_get_or_free (gras_set_cursor_t **cursor,
                                          gras_set_elm_t    **elm);
 
 #define gras_set_foreach(set,cursor,elm)                       \
-  for (cursor=NULL, gras_set_cursor_first((set),&(cursor)) ;   \
+  for ((cursor) = NULL, gras_set_cursor_first((set),&(cursor)) ;   \
        gras_set_cursor_get_or_free(&(cursor),(gras_set_elm_t**)&(elm));          \
        gras_set_cursor_step(cursor) )