Avoid inheritance

This commit is contained in:
Ion Gaztañaga
2015-04-14 14:56:38 +02:00
parent bb95a6f8cf
commit eebabce934

View File

@@ -23,6 +23,7 @@
#include <boost/intrusive/detail/config_begin.hpp>
#include <boost/intrusive/detail/mpl.hpp>
#include <boost/intrusive/detail/iterator.hpp>
namespace boost {
namespace intrusive {
@@ -58,14 +59,14 @@ struct operator_arrow_proxy<T&>
template <class Iterator, class UnaryFunction>
class transform_iterator
: public boost::intrusive::iterator
< typename Iterator::iterator_category
, typename detail::remove_reference<typename UnaryFunction::result_type>::type
, typename Iterator::difference_type
, operator_arrow_proxy<typename UnaryFunction::result_type>
, typename UnaryFunction::result_type>
{
public:
typedef typename Iterator::iterator_category iterator_category;
typedef typename detail::remove_reference<typename UnaryFunction::result_type>::type value_type;
typedef typename Iterator::difference_type difference_type;
typedef operator_arrow_proxy<typename UnaryFunction::result_type> pointer;
typedef typename UnaryFunction::result_type reference;
explicit transform_iterator(const Iterator &it, const UnaryFunction &f = UnaryFunction())
: members_(it, f)
{}