Move probabilistic code into zeek namespaces

This commit is contained in:
Tim Wojtulewicz 2020-08-01 10:48:36 -07:00
parent be92bd536f
commit f310795d79
17 changed files with 162 additions and 118 deletions

View file

@ -10,7 +10,7 @@
#include "digest.h"
using namespace probabilistic;
namespace zeek::probabilistic::detail {
BitVector::size_type BitVector::npos = static_cast<BitVector::size_type>(-1);
BitVector::block_type BitVector::bits_per_block =
@ -263,8 +263,6 @@ BitVector& BitVector::operator-=(BitVector const& other)
return *this;
}
namespace probabilistic {
BitVector operator&(BitVector const& x, BitVector const& y)
{
BitVector b(x);
@ -318,8 +316,6 @@ bool operator<(BitVector const& x, BitVector const& y)
return false;
}
}
void BitVector::Resize(size_type n, bool value)
{
size_type old = Blocks();
@ -581,3 +577,5 @@ BitVector::size_type BitVector::find_from(size_type i) const
return i * bits_per_block + lowest_bit(bits[i]);
}
} // namespace zeek::probabilistic::detail