From ced399c6fc385b3f5e136c120ad398f47393b351 Mon Sep 17 00:00:00 2001 From: Todd Gruben Date: Tue, 30 Aug 2016 17:36:00 -0500 Subject: [PATCH] corrected ClearBit --- bitmap.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bitmap.go b/bitmap.go index b9a56a802..083ed1529 100644 --- a/bitmap.go +++ b/bitmap.go @@ -127,7 +127,7 @@ func (b *Bitmap) SetBit(i uint64) (changed bool) { // ClearBit clears the i-th bit of the bitmap. func (b *Bitmap) ClearBit(i uint64) (changed bool) { - return b.createSegmentIfNotExists(i / SliceWidth).SetBit(i) + return b.createSegmentIfNotExists(i / SliceWidth).ClearBit(i) } func (b *Bitmap) createSegmentIfNotExists(slice uint64) *BitmapSegment {