From f105d546d0d58cbae46407731760770545369d88 Mon Sep 17 00:00:00 2001 From: Hackerpilot Date: Thu, 8 Nov 2018 15:10:29 -0800 Subject: [PATCH] Code cleanup --- src/containers/hashset.d | 10 ++-------- src/containers/internal/hash.d | 2 -- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/src/containers/hashset.d b/src/containers/hashset.d index 777ce64..431163f 100644 --- a/src/containers/hashset.d +++ b/src/containers/hashset.d @@ -329,19 +329,13 @@ private: static if (storeHash) { immutable Hash hash = node.items[i].hash; - version (BITMASK) - size_t index = (hash, Mask); - else - size_t index = hashToIndex(hash, buckets.length); + size_t index = hashToIndex(hash, buckets.length); buckets[index].insert(ItemNode(hash, node.items[i].value)); } else { immutable Hash hash = hashFunction(node.items[i].value); - version (BITMASK) - size_t index = (hash, mask); - else - size_t index = hashToIndex(hash, buckets.length); + size_t index = hashToIndex(hash, buckets.length); buckets[index].insert(ItemNode(node.items[i].value)); } } diff --git a/src/containers/internal/hash.d b/src/containers/internal/hash.d index 28a14c0..f28fd81 100644 --- a/src/containers/internal/hash.d +++ b/src/containers/internal/hash.d @@ -6,8 +6,6 @@ */ module containers.internal.hash; -import std.conv : to; - static if (hash_t.sizeof == 4) { hash_t generateHash(T)(const T value)