From d70e28403f07e88b276c6bd9f162d2a428530f2e Mon Sep 17 00:00:00 2001 From: Kenneth Heafield Date: Wed, 4 Nov 2020 09:19:53 +0000 Subject: MSVC doesn't like const Proxy operator*() const. Fixes #308 --- util/proxy_iterator.hh | 3 +-- 1 file changed, 1 insertion(+), 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 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); } -- cgit v1.2.3