diff options
author | Determinant <ted.sybil@gmail.com> | 2018-07-16 03:27:22 -0400 |
---|---|---|
committer | Determinant <ted.sybil@gmail.com> | 2018-07-16 03:27:22 -0400 |
commit | 71874620e59d2ccf1d5a4f1c39c06bd2b5b0068f (patch) | |
tree | 2a13eac565d1a504a7a89b01ad51e2c6cb59d8b1 /include/salticidae/stream.h | |
parent | 766ef262f1413eaef755ea567f69c25a1d26351d (diff) |
use EventContext wrapper
Diffstat (limited to 'include/salticidae/stream.h')
-rw-r--r-- | include/salticidae/stream.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/salticidae/stream.h b/include/salticidae/stream.h index efca394..03b9d13 100644 --- a/include/salticidae/stream.h +++ b/include/salticidae/stream.h @@ -374,6 +374,10 @@ class _Bits { auto pos = idx & (bit_per_datum - 1); data[i] ^= ((_impl_type)1) << pos; } + + void clear() { + memset(data.get(), 0, ndata * sizeof(_impl_type)); + } uint8_t operator[](uint32_t idx) const { return get(idx); } |