summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mesa/program/hash_table.h14
-rw-r--r--src/util/hash_table.h13
2 files changed, 13 insertions, 14 deletions
diff --git a/src/mesa/program/hash_table.h b/src/mesa/program/hash_table.h
index 687a9963c6e..421d0e9dc5c 100644
--- a/src/mesa/program/hash_table.h
+++ b/src/mesa/program/hash_table.h
@@ -214,20 +214,6 @@ hash_table_pointer_compare(const void *key1, const void *key2)
return _mesa_key_pointer_equal(key1, key2);
}
-
-static inline void
-hash_table_call_foreach(struct hash_table *ht,
- void (*callback)(const void *key,
- void *data,
- void *closure),
- void *closure)
-{
- struct hash_entry *entry;
-
- hash_table_foreach(ht, entry)
- callback(entry->key, entry->data, closure);
-}
-
struct string_to_uint_map *
string_to_uint_map_ctor();
diff --git a/src/util/hash_table.h b/src/util/hash_table.h
index c69abfa3e64..b35ee871bb3 100644
--- a/src/util/hash_table.h
+++ b/src/util/hash_table.h
@@ -139,6 +139,19 @@ _mesa_fnv32_1a_accumulate_block(uint32_t hash, const void *data, size_t size)
entry != NULL; \
entry = _mesa_hash_table_next_entry(ht, entry))
+static inline void
+hash_table_call_foreach(struct hash_table *ht,
+ void (*callback)(const void *key,
+ void *data,
+ void *closure),
+ void *closure)
+{
+ struct hash_entry *entry;
+
+ hash_table_foreach(ht, entry)
+ callback(entry->key, entry->data, closure);
+}
+
#ifdef __cplusplus
} /* extern C */
#endif