forked from boostorg/iterator
Remove tabs in file.
[SVN r24043]
This commit is contained in:
@ -10,7 +10,7 @@
|
|||||||
|
|
||||||
struct node_base
|
struct node_base
|
||||||
{
|
{
|
||||||
node_base() : m_next(0) {}
|
node_base() : m_next(0) {}
|
||||||
|
|
||||||
virtual ~node_base()
|
virtual ~node_base()
|
||||||
{
|
{
|
||||||
@ -34,7 +34,7 @@ struct node_base
|
|||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
node_base* m_next;
|
node_base* m_next;
|
||||||
};
|
};
|
||||||
|
|
||||||
inline std::ostream& operator<<(std::ostream& s, node_base const& n)
|
inline std::ostream& operator<<(std::ostream& s, node_base const& n)
|
||||||
|
@ -15,24 +15,24 @@ class node_iterator
|
|||||||
>
|
>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
node_iterator()
|
node_iterator()
|
||||||
: m_node(0)
|
: m_node(0)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
explicit node_iterator(node_base* p)
|
explicit node_iterator(node_base* p)
|
||||||
: m_node(p)
|
: m_node(p)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
friend class boost::iterator_core_access;
|
friend class boost::iterator_core_access;
|
||||||
|
|
||||||
void increment()
|
void increment()
|
||||||
{ m_node = m_node->next(); }
|
{ m_node = m_node->next(); }
|
||||||
|
|
||||||
bool equal(node_iterator const& other) const
|
bool equal(node_iterator const& other) const
|
||||||
{ return this->m_node == other.m_node; }
|
{ return this->m_node == other.m_node; }
|
||||||
|
|
||||||
node_base& dereference() const
|
node_base& dereference() const
|
||||||
{ return *m_node; }
|
{ return *m_node; }
|
||||||
|
|
||||||
node_base* m_node;
|
node_base* m_node;
|
||||||
|
@ -89,7 +89,7 @@ main()
|
|||||||
boost_concepts::RandomAccessTraversalConcept<old_iterator> >();
|
boost_concepts::RandomAccessTraversalConcept<old_iterator> >();
|
||||||
|
|
||||||
boost::function_requires<
|
boost::function_requires<
|
||||||
boost_concepts::InteroperableIteratorConcept<int*, int const*> >();
|
boost_concepts::InteroperableIteratorConcept<int*, int const*> >();
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -43,9 +43,9 @@ int main()
|
|||||||
STATIC_ASSERT_SAME(Iter::difference_type, std::ptrdiff_t);
|
STATIC_ASSERT_SAME(Iter::difference_type, std::ptrdiff_t);
|
||||||
|
|
||||||
BOOST_STATIC_ASSERT((boost::is_convertible<Iter::iterator_category,
|
BOOST_STATIC_ASSERT((boost::is_convertible<Iter::iterator_category,
|
||||||
std::random_access_iterator_tag>::value));
|
std::random_access_iterator_tag>::value));
|
||||||
BOOST_STATIC_ASSERT((boost::is_convertible<boost::iterator_traversal<Iter>::type,
|
BOOST_STATIC_ASSERT((boost::is_convertible<boost::iterator_traversal<Iter>::type,
|
||||||
boost::random_access_traversal_tag>::value));
|
boost::random_access_traversal_tag>::value));
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
typedef boost::indirect_iterator<int const**> Iter;
|
typedef boost::indirect_iterator<int const**> Iter;
|
||||||
@ -74,9 +74,9 @@ int main()
|
|||||||
STATIC_ASSERT_SAME(Iter::difference_type, std::ptrdiff_t);
|
STATIC_ASSERT_SAME(Iter::difference_type, std::ptrdiff_t);
|
||||||
|
|
||||||
BOOST_STATIC_ASSERT((boost::is_convertible<Iter::iterator_category,
|
BOOST_STATIC_ASSERT((boost::is_convertible<Iter::iterator_category,
|
||||||
std::random_access_iterator_tag>::value));
|
std::random_access_iterator_tag>::value));
|
||||||
BOOST_STATIC_ASSERT((boost::is_convertible<boost::iterator_traversal<Iter>::type,
|
BOOST_STATIC_ASSERT((boost::is_convertible<boost::iterator_traversal<Iter>::type,
|
||||||
boost::random_access_traversal_tag>::value));
|
boost::random_access_traversal_tag>::value));
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
typedef boost::indirect_iterator<char**, int, std::random_access_iterator_tag, long&, short> Iter;
|
typedef boost::indirect_iterator<char**, int, std::random_access_iterator_tag, long&, short> Iter;
|
||||||
|
Reference in New Issue
Block a user