Index: src/utils.h |
diff --git a/src/utils.h b/src/utils.h |
index b89f2849bfde4d5c2624d94bc14993291ac8608d..6f89766c16dcdc424f5b3e6f27017471f66c9035 100644 |
--- a/src/utils.h |
+++ b/src/utils.h |
@@ -251,6 +251,12 @@ static inline uint32_t ComputeIntegerHash(uint32_t key) { |
} |
+static inline uint32_t ComputePointerHash(void* ptr) { |
+ return ComputeIntegerHash( |
+ static_cast<uint32_t>(reinterpret_cast<intptr_t>(ptr))); |
+} |
+ |
+ |
// ---------------------------------------------------------------------------- |
// Miscellaneous |