From d727be2fa7b062e3862119123f4d07bf208c3b4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Erik=20S=C3=B8e=20S=C3=B8rensen?= Date: Tue, 25 Sep 2012 14:51:45 +0200 Subject: [PATCH] Bloom filter: remove double-testing introduced in dispatch. --- src/hanoidb_bloom.erl | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/hanoidb_bloom.erl b/src/hanoidb_bloom.erl index 369b865..29f11d9 100644 --- a/src/hanoidb_bloom.erl +++ b/src/hanoidb_bloom.erl @@ -148,12 +148,9 @@ masked_pair(Mask, X, Y) -> {X band Mask, Y band Mask}. all_set(_Mask, _I1, _I, []) -> true; all_set(Mask, I1, I, [H|T]) -> - case element(1, H) of - array -> - case bitmask_get(I, H) of - true -> all_set(Mask, I1, (I+I1) band Mask, T); - false -> false - end + case bitmask_get(I, H) of + true -> all_set(Mask, I1, (I+I1) band Mask, T); + false -> false end. %% Adds element to set