minor semantic updates
@@ -5486,10 +5486,10 @@ Done
* Note: FIO_SET_HASH_TYPE should, normaly be left alone (uintptr_t is
* enough). Also, the hash value 0 is reserved to indicate an empty slot.
*
- * Note: the FIO_SET_OBJ_COMPARE for Sets or the FIO_SET_KEY_COMPARE will be
- * used to compare against invalid as well as valid objects. Invalid
- * objects have their bytes all zero. FIO_SET_*_DESTROY should somehow
- * mark them as invalid.
+ * Note: the FIO_SET_OBJ_COMPARE or the FIO_SET_KEY_COMPARE will be used to
+ * compare against invalid as well as valid objects. Invalid objects have
+ * their bytes all zero. FIO_SET_*_DESTROY should somehow mark them as
+ * invalid.
*
* Note: Before freeing the Set, FIO_SET_OBJ_DESTROY will be automatically
* called for every existing object.
@@ -5602,16 +5602,16 @@ typedef struct {
#endif
/* The default Hash Map-Set has will use straight euqality operators */
-#if !defined(FIO_SET_KEY_COMPARE)
+#ifndef FIO_SET_KEY_COMPARE
#define FIO_SET_KEY_COMPARE(o1, o2) ((o1) == (o2))
#endif
/** Internal macros for object actions in Hash mode */
#define FIO_SET_COMPARE(o1, o2) FIO_SET_KEY_COMPARE((o1).key, (o2).key)
-#define FIO_SET_COPY(dest, org) \
+#define FIO_SET_COPY(dest, src) \
do { \
- FIO_SET_OBJ_COPY((dest).obj, (org).obj); \
- FIO_SET_KEY_COPY((dest).key, (org).key); \
+ FIO_SET_OBJ_COPY((dest).obj, (src).obj); \
+ FIO_SET_KEY_COPY((dest).key, (src).key); \
} while (0);
#define FIO_SET_DESTROY(couplet) \
do { \
@@ -5863,7 +5863,7 @@ FIO_FUNC inline FIO_NAME(_map_s_) *
if (FIO_SET_HASH_COMPARE(FIO_SET_HASH_INVALID, pos->hash))
return pos;
if (FIO_SET_HASH_COMPARE(pos->hash, hash_value_i)) {
- if (!pos->pos || FIO_SET_COMPARE(pos->pos->obj, obj))
+ if (!pos->pos || (FIO_SET_COMPARE(pos->pos->obj, obj)))
return pos;
/* full hash value collision detected */
set->has_collisions = 1;
@@ -5882,7 +5882,7 @@ FIO_FUNC inline FIO_NAME(_map_s_) *
if (FIO_SET_HASH_COMPARE(FIO_SET_HASH_INVALID, pos->hash))
return pos;
if (FIO_SET_HASH_COMPARE(pos->hash, hash_value_i)) {
- if (!pos->pos || FIO_SET_COMPARE(pos->pos->obj, obj))
+ if (!pos->pos || (FIO_SET_COMPARE(pos->pos->obj, obj)))
return pos;
/* full hash value collision detected */
set->has_collisions = 1;
