From 1e4b94b32a6969c5a2a18fd227d626b8016afe90 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ion=20Gazta=C3=B1aga?= Date: Tue, 14 Apr 2015 14:55:39 +0200 Subject: [PATCH] Add iterator_arrow_result utility --- include/boost/intrusive/detail/iterator.hpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/include/boost/intrusive/detail/iterator.hpp b/include/boost/intrusive/detail/iterator.hpp index fb6fb81..9f0fe60 100644 --- a/include/boost/intrusive/detail/iterator.hpp +++ b/include/boost/intrusive/detail/iterator.hpp @@ -141,6 +141,14 @@ typename iterator_enable_if_tag_difference_type return off; } +template +typename iterator_traits::pointer iterator_arrow_result(const I &i) +{ return i.operator->(); } + +template +T * iterator_arrow_result(T *p) +{ return p; } + } //namespace intrusive } //namespace boost