- /**
- * https://quuxplusone.github.io/blog/2019/02/06/arrow-proxy/
- */
- #pragma once
- namespace iterator::detail {
- template <typename Reference> struct ArrowProxy {
- ArrowProxy(Reference r) : r(std::move(r)) {}
- Reference r;
- Reference * operator->() { return std::addressof(r); }
- };
- template <typename R> ArrowProxy(R r) -> ArrowProxy<R>;
- }
|