Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/core/StarPythonic.hpp
diff options
context:
space:
mode:
authorLDA <lda@ldasuku.net>2023-06-26 11:48:27 -0700
committerLDA <lda@ldasuku.net>2023-06-26 11:58:35 -0700
commitc9e889723b7af832322d178975e6e440d6cd3ae5 (patch)
treea8429c30ecf46ed1388df13b614141e73973cd9f /source/core/StarPythonic.hpp
parent4585c9cafa87cad6b54397af7e9375cc31b72f89 (diff)
resolved most of the compiler warnings/errors under gcc
also update xxhash and tinyformat
Diffstat (limited to 'source/core/StarPythonic.hpp')
-rw-r--r--source/core/StarPythonic.hpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/source/core/StarPythonic.hpp b/source/core/StarPythonic.hpp
index 014e14e..0bfdc50 100644
--- a/source/core/StarPythonic.hpp
+++ b/source/core/StarPythonic.hpp
@@ -303,7 +303,13 @@ namespace RangeHelper {
STAR_EXCEPTION(RangeException, StarException);
template <typename Value, typename Diff = int>
-class RangeIterator : public std::iterator<std::random_access_iterator_tag, Value> {
+class RangeIterator {
+ using iterator_category = std::random_access_iterator_tag;
+ using value_type = Value;
+ using difference_type = Diff;
+ using pointer = Value*;
+ using reference = Value&;
+
public:
RangeIterator() : m_start(), m_end(), m_diff(1), m_current(), m_stop(true) {}
@@ -342,7 +348,7 @@ public:
return *this;
}
- RangeIterator operator-=(Diff steps) const {
+ RangeIterator operator-=(Diff steps) {
m_stop = false;
sanity();