AlexanderSaydakov commented on a change in pull request #209:
URL: https://github.com/apache/datasketches-cpp/pull/209#discussion_r616141444



##########
File path: hll/include/HllUnion-internal.hpp
##########
@@ -32,151 +32,151 @@
 namespace datasketches {
 
 template<typename A>
-hll_union_alloc<A>::hll_union_alloc(const int lg_max_k, const A& allocator):
-  lg_max_k(HllUtil<A>::checkLgK(lg_max_k)),
-  gadget(lg_max_k, target_hll_type::HLL_8, false, allocator)
+hll_union_alloc<A>::hll_union_alloc(uint8_t lg_max_k, const A& allocator):
+  lg_max_k_(HllUtil<A>::checkLgK(lg_max_k)),
+  gadget_(lg_max_k, target_hll_type::HLL_8, false, allocator)
 {}
 
 template<typename A>
 hll_sketch_alloc<A> hll_union_alloc<A>::get_result(target_hll_type 
target_type) const {
-  return hll_sketch_alloc<A>(gadget, target_type);
+  return hll_sketch_alloc<A>(gadget_, target_type);
 }
 
 template<typename A>
 void hll_union_alloc<A>::update(const hll_sketch_alloc<A>& sketch) {
   if (sketch.is_empty()) return;
-  union_impl(sketch, lg_max_k);
+  union_impl(sketch, lg_max_k_);
 }
 
 template<typename A>
 void hll_union_alloc<A>::update(hll_sketch_alloc<A>&& sketch) {
   if (sketch.is_empty()) return;
-  if (gadget.is_empty() && sketch.get_target_type() == HLL_8 && 
sketch.get_lg_config_k() <= lg_max_k) {
-    if (sketch.get_current_mode() == HLL || sketch.get_lg_config_k() == 
lg_max_k) {
-      gadget = std::move(sketch);
+  if (gadget_.is_empty() && sketch.get_target_type() == HLL_8 && 
sketch.get_lg_config_k() <= lg_max_k_) {
+    if (sketch.get_current_mode() == HLL || sketch.get_lg_config_k() == 
lg_max_k_) {
+      gadget_ = std::move(sketch);
     }
   }
-  union_impl(sketch, lg_max_k);
+  union_impl(sketch, lg_max_k_);
 }
 
 template<typename A>
 void hll_union_alloc<A>::update(const std::string& datum) {
-  gadget.update(datum);
+  gadget_.update(datum);
 }
 
 template<typename A>
 void hll_union_alloc<A>::update(const uint64_t datum) {

Review comment:
       yes, missed a few




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to