mirror of
https://github.com/boostorg/container.git
synced 2025-08-02 14:04:26 +02:00
Define nat in iterators to allow explicit instantiation of iterators.
This commit is contained in:
@@ -297,12 +297,7 @@ class stable_vector_iterator
|
|||||||
>::type pointer;
|
>::type pointer;
|
||||||
typedef boost::intrusive::pointer_traits<pointer> ptr_traits;
|
typedef boost::intrusive::pointer_traits<pointer> ptr_traits;
|
||||||
typedef typename ptr_traits::reference reference;
|
typedef typename ptr_traits::reference reference;
|
||||||
class nat;
|
|
||||||
typedef typename dtl::if_c< IsConst
|
|
||||||
, stable_vector_iterator<Pointer, false>
|
|
||||||
, nat>::type nonconst_iterator;
|
|
||||||
|
|
||||||
private:
|
|
||||||
typedef typename non_const_ptr_traits::template
|
typedef typename non_const_ptr_traits::template
|
||||||
rebind_pointer<void>::type void_ptr;
|
rebind_pointer<void>::type void_ptr;
|
||||||
typedef stable_vector_detail::node<Pointer> node_type;
|
typedef stable_vector_detail::node<Pointer> node_type;
|
||||||
@@ -316,6 +311,16 @@ class stable_vector_iterator
|
|||||||
typedef typename non_const_ptr_traits::template
|
typedef typename non_const_ptr_traits::template
|
||||||
rebind_pointer<node_base_ptr>::type node_base_ptr_ptr;
|
rebind_pointer<node_base_ptr>::type node_base_ptr_ptr;
|
||||||
|
|
||||||
|
class nat
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
node_base_ptr node_pointer() const
|
||||||
|
{ return node_base_ptr(); }
|
||||||
|
};
|
||||||
|
typedef typename dtl::if_c< IsConst
|
||||||
|
, stable_vector_iterator<Pointer, false>
|
||||||
|
, nat>::type nonconst_iterator;
|
||||||
|
|
||||||
node_base_ptr m_pn;
|
node_base_ptr m_pn;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
@@ -96,7 +96,13 @@ class vec_iterator
|
|||||||
#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED
|
#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED
|
||||||
private:
|
private:
|
||||||
Pointer m_ptr;
|
Pointer m_ptr;
|
||||||
class nat;
|
|
||||||
|
class nat
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
Pointer get_ptr() const
|
||||||
|
{ return Pointer(); }
|
||||||
|
};
|
||||||
typedef typename dtl::if_c< IsConst
|
typedef typename dtl::if_c< IsConst
|
||||||
, vec_iterator<Pointer, false>
|
, vec_iterator<Pointer, false>
|
||||||
, nat>::type nonconst_iterator;
|
, nat>::type nonconst_iterator;
|
||||||
|
Reference in New Issue
Block a user