Fix merging util::statistics
This commit is contained in:
parent
ba8b33d49e
commit
954068ba3a
1 changed files with 3 additions and 1 deletions
|
|
@ -236,7 +236,8 @@ namespace psemek::util
|
||||||
|
|
||||||
template <typename T>
|
template <typename T>
|
||||||
statistics_log_bucket<T>::statistics_log_bucket(statistics_log_bucket && other)
|
statistics_log_bucket<T>::statistics_log_bucket(statistics_log_bucket && other)
|
||||||
: precision_(other.precision_)
|
: statistics_lite<T>(other.lite())
|
||||||
|
, precision_(other.precision_)
|
||||||
, zero_count_(other.zero_count_)
|
, zero_count_(other.zero_count_)
|
||||||
, buckets_(std::move(other.buckets_))
|
, buckets_(std::move(other.buckets_))
|
||||||
, prefix_count_(std::move(other.prefix_count_))
|
, prefix_count_(std::move(other.prefix_count_))
|
||||||
|
|
@ -250,6 +251,7 @@ namespace psemek::util
|
||||||
if (this == &other)
|
if (this == &other)
|
||||||
return *this;
|
return *this;
|
||||||
|
|
||||||
|
static_cast<statistics_lite<T> &>(*this) = other.lite();
|
||||||
precision_ = other.precision_;
|
precision_ = other.precision_;
|
||||||
zero_count_ = other.zero_count_;
|
zero_count_ = other.zero_count_;
|
||||||
buckets_ = std::move(other.buckets_);
|
buckets_ = std::move(other.buckets_);
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue