diff options
author | Kenneth Heafield <github@kheafield.com> | 2020-11-04 12:19:53 +0300 |
---|---|---|
committer | Kenneth Heafield <github@kheafield.com> | 2020-11-04 12:19:53 +0300 |
commit | d70e28403f07e88b276c6bd9f162d2a428530f2e (patch) | |
tree | 8ed690a39612936c6aea8ba793bb5722696c7d86 | |
parent | a6e130e7854ffd5d75ba7b29ba2479e7ad3a9244 (diff) |
MSVC doesn't like const Proxy operator*() const.
Fixes #308
-rw-r--r-- | util/proxy_iterator.hh | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/util/proxy_iterator.hh b/util/proxy_iterator.hh index 8aa697b..9de2663 100644 --- a/util/proxy_iterator.hh +++ b/util/proxy_iterator.hh @@ -77,8 +77,7 @@ template <class Proxy> class ProxyIterator { std::ptrdiff_t operator-(const S &other) const { return I() - other.I(); } - Proxy operator*() { return p_; } - const Proxy operator*() const { return p_; } + Proxy operator*() const { return p_; } Proxy *operator->() { return &p_; } const Proxy *operator->() const { return &p_; } Proxy operator[](std::ptrdiff_t amount) const { return *(*this + amount); } |