hashable 1.2.0.1 → 1.2.0.2
raw patch · 2 files changed
+12/−1 lines, 2 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- cbits/siphash.c +11/−0
- hashable.cabal +1/−1
cbits/siphash.c view
@@ -117,6 +117,15 @@ #endif +/* On Windows, ghci's linker fails to call static initializers. */+static inline void ensure_sse_init()+{+#if defined(_WIN32) && defined(__i386)+ if (_siphash24 == NULL)+ maybe_use_sse();+#endif+}+ u64 hashable_siphash(int c, int d, u64 k0, u64 k1, const u8 *str, size_t len) { return _siphash(c, d, k0, k1, str, len);@@ -124,6 +133,7 @@ u64 hashable_siphash24(u64 k0, u64 k1, const u8 *str, size_t len) {+ ensure_sse_init(); return _siphash24(k0, k1, str, len); } @@ -133,6 +143,7 @@ u64 hashable_siphash24_offset(u64 k0, u64 k1, const u8 *str, size_t off, size_t len) {+ ensure_sse_init(); return _siphash24(k0, k1, str + off, len); }
hashable.cabal view
@@ -1,5 +1,5 @@ Name: hashable-Version: 1.2.0.1+Version: 1.2.0.2 Synopsis: A class for types that can be converted to a hash value Description: This package defines a class, 'Hashable', for types that can be converted to a hash value. This class