types: Add hash function for IPs

Change-Id: I232443d68aee32eb1d52c98ceecccd43700397a1
Signed-off-by: William A. Kennington III <wak@google.com>
diff --git a/src/types.hpp b/src/types.hpp
index 53619ea..342c8cc 100644
--- a/src/types.hpp
+++ b/src/types.hpp
@@ -156,6 +156,18 @@
     }
 };
 
+template <>
+struct std::hash<in_addr>
+{
+    std::size_t operator()(in_addr addr) const noexcept;
+};
+
+template <>
+struct std::hash<in6_addr>
+{
+    std::size_t operator()(in6_addr addr) const noexcept;
+};
+
 namespace fmt
 {
 template <>