summaryrefslogtreecommitdiff
path: root/boost/container/detail/transform_iterator.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/container/detail/transform_iterator.hpp')
-rw-r--r--boost/container/detail/transform_iterator.hpp15
1 files changed, 9 insertions, 6 deletions
diff --git a/boost/container/detail/transform_iterator.hpp b/boost/container/detail/transform_iterator.hpp
index c4e746c389..ba64c7de79 100644
--- a/boost/container/detail/transform_iterator.hpp
+++ b/boost/container/detail/transform_iterator.hpp
@@ -14,15 +14,18 @@
#ifndef BOOST_CONTAINER_DETAIL_TRANSFORM_ITERATORS_HPP
#define BOOST_CONTAINER_DETAIL_TRANSFORM_ITERATORS_HPP
-#if defined(_MSC_VER)
+#ifndef BOOST_CONFIG_HPP
+# include <boost/config.hpp>
+#endif
+
+#if defined(BOOST_HAS_PRAGMA_ONCE)
# pragma once
#endif
#include <boost/container/detail/config_begin.hpp>
#include <boost/container/detail/workaround.hpp>
-
#include <boost/container/detail/type_traits.hpp>
-#include <iterator>
+#include <boost/container/detail/iterator.hpp>
namespace boost {
namespace container {
@@ -58,7 +61,7 @@ struct operator_arrow_proxy<T&>
template <class Iterator, class UnaryFunction>
class transform_iterator
: public UnaryFunction
- , public std::iterator
+ , public boost::container::iterator
< typename Iterator::iterator_category
, typename container_detail::remove_reference<typename UnaryFunction::result_type>::type
, typename Iterator::difference_type
@@ -156,10 +159,10 @@ class transform_iterator
{ return UnaryFunction::operator()(*m_it); }
void advance(typename Iterator::difference_type n)
- { std::advance(m_it, n); }
+ { boost::container::iterator_advance(m_it, n); }
typename Iterator::difference_type distance_to(const transform_iterator &other)const
- { return std::distance(other.m_it, m_it); }
+ { return boost::container::iterator_distance(other.m_it, m_it); }
};
template <class Iterator, class UnaryFunc>