You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datasketches.apache.org by jm...@apache.org on 2023/05/03 23:34:58 UTC
[datasketches-cpp] 01/01: remove std::iterator from wrapped_compact_theta_sketch_alloc
This is an automated email from the ASF dual-hosted git repository.
jmalkin pushed a commit to branch theta_iterator_fix
in repository https://gitbox.apache.org/repos/asf/datasketches-cpp.git
commit 88adf3aa78bee8680c39f9c8ae04cb4807f2abfb
Author: Jon <jm...@apache.org>
AuthorDate: Wed May 3 16:34:43 2023 -0700
remove std::iterator from wrapped_compact_theta_sketch_alloc
---
theta/include/theta_sketch.hpp | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/theta/include/theta_sketch.hpp b/theta/include/theta_sketch.hpp
index b374d14..de79eb2 100644
--- a/theta/include/theta_sketch.hpp
+++ b/theta/include/theta_sketch.hpp
@@ -471,8 +471,14 @@ private:
};
template<typename Allocator>
-class wrapped_compact_theta_sketch_alloc<Allocator>::const_iterator: public std::iterator<std::input_iterator_tag, uint64_t> {
+class wrapped_compact_theta_sketch_alloc<Allocator>::const_iterator {
public:
+ using iterator_category = std::input_iterator_tag;
+ using value_type = uint64_t;
+ using difference_type = void;
+ using pointer = uint64_t*;
+ using reference = uint64_t;
+
const_iterator(const void* ptr, uint8_t entry_bits, uint32_t num_entries, uint32_t index);
const_iterator& operator++();
const_iterator operator++(int);
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org