From a3d3c28ccc8a8a7b11b2614cbf2d9813c382cb5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thorsten=20J=C3=B8rgen=20Ottosen?= Date: Mon, 16 Aug 2004 22:07:07 +0000 Subject: [PATCH] updated naming convention [SVN r24517] --- include/boost/range/begin.hpp | 20 ++++---- include/boost/range/const_iterator.hpp | 18 +++---- .../boost/range/const_reverse_iterator.hpp | 4 +- include/boost/range/detail/begin.hpp | 6 +-- include/boost/range/detail/const_iterator.hpp | 2 +- .../boost/range/detail/difference_type.hpp | 2 +- include/boost/range/detail/end.hpp | 10 ++-- include/boost/range/detail/iterator.hpp | 2 +- include/boost/range/detail/size.hpp | 33 ++++++------ include/boost/range/detail/size_type.hpp | 5 +- include/boost/range/detail/value_type.hpp | 5 +- include/boost/range/difference_type.hpp | 18 +++---- include/boost/range/empty.hpp | 8 +-- include/boost/range/end.hpp | 20 ++++---- include/boost/range/iterator.hpp | 18 +++---- include/boost/range/iterator_range.hpp | 12 ++--- include/boost/range/rbegin.hpp | 12 ++--- include/boost/range/rend.hpp | 12 ++--- include/boost/range/result_iterator.hpp | 6 +-- include/boost/range/reverse_iterator.hpp | 4 +- .../boost/range/reverse_result_iterator.hpp | 4 +- include/boost/range/size.hpp | 8 +-- include/boost/range/size_type.hpp | 18 +++---- include/boost/range/sub_range.hpp | 14 +++--- include/boost/range/value_type.hpp | 18 +++---- test/Jamfile | 2 +- test/algorithm_example.cpp | 10 ++-- test/array.cpp | 28 +++++------ test/iterator_pair.cpp | 28 +++++------ test/reversible_range.cpp | 14 +++--- test/std_container.cpp | 24 ++++----- test/string.cpp | 50 +++++++++---------- 32 files changed, 219 insertions(+), 216 deletions(-) diff --git a/include/boost/range/begin.hpp b/include/boost/range/begin.hpp index a4e1398..542542b 100755 --- a/include/boost/range/begin.hpp +++ b/include/boost/range/begin.hpp @@ -26,7 +26,7 @@ namespace boost { -namespace range +namespace range_detail { ////////////////////////////////////////////////////////////////////// @@ -34,14 +34,14 @@ namespace range ////////////////////////////////////////////////////////////////////// template< typename C > - inline BOOST_DEDUCED_TYPENAME const_iterator_of::type + inline BOOST_DEDUCED_TYPENAME range_const_iterator::type begin( const C& c ) { return c.begin(); } template< typename C > - inline BOOST_DEDUCED_TYPENAME iterator_of::type + inline BOOST_DEDUCED_TYPENAME range_iterator::type begin( C& c ) { return c.begin(); @@ -104,28 +104,28 @@ namespace range return s; } -} // namespace 'range' +} // namespace 'range_detail' template< class T > -inline BOOST_DEDUCED_TYPENAME iterator_of::type begin( T& r ) +inline BOOST_DEDUCED_TYPENAME range_iterator::type begin( T& r ) { #if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - using range::begin; + using range_detail::begin; return begin( r ); #else - return range::begin( r ); + return range_detail::begin( r ); #endif } template< class T > -inline BOOST_DEDUCED_TYPENAME const_iterator_of::type begin( const T& r ) +inline BOOST_DEDUCED_TYPENAME range_const_iterator::type begin( const T& r ) { #if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - using range::begin; + using range_detail::begin; return begin( r ); #else - return range::begin( r ); + return range_detail::begin( r ); #endif } diff --git a/include/boost/range/const_iterator.hpp b/include/boost/range/const_iterator.hpp index b05df54..81bd401 100755 --- a/include/boost/range/const_iterator.hpp +++ b/include/boost/range/const_iterator.hpp @@ -31,7 +31,7 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename C > - struct const_iterator_of + struct range_const_iterator { typedef BOOST_DEDUCED_TYPENAME C::const_iterator type; }; @@ -41,13 +41,13 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename Iterator > - struct const_iterator_of< std::pair > + struct range_const_iterator< std::pair > { typedef Iterator type; }; template< typename Iterator > - struct const_iterator_of< const std::pair > + struct range_const_iterator< const std::pair > { typedef Iterator type; }; @@ -57,13 +57,13 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename T, std::size_t sz > - struct const_iterator_of< T[sz] > + struct range_const_iterator< T[sz] > { typedef const T* type; }; template< typename T, std::size_t sz > - struct const_iterator_of< const T[sz] > + struct range_const_iterator< const T[sz] > { typedef const T* type; }; @@ -73,25 +73,25 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template<> - struct const_iterator_of< char* > + struct range_const_iterator< char* > { typedef const char* type; }; template<> - struct const_iterator_of< wchar_t* > + struct range_const_iterator< wchar_t* > { typedef const wchar_t* type; }; template<> - struct const_iterator_of< const char* > + struct range_const_iterator< const char* > { typedef const char* type; }; template<> - struct const_iterator_of< const wchar_t* > + struct range_const_iterator< const wchar_t* > { typedef const wchar_t* type; }; diff --git a/include/boost/range/const_reverse_iterator.hpp b/include/boost/range/const_reverse_iterator.hpp index e0fef78..f33f63d 100755 --- a/include/boost/range/const_reverse_iterator.hpp +++ b/include/boost/range/const_reverse_iterator.hpp @@ -26,10 +26,10 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename C > - struct const_reverse_iterator_of + struct range_const_reverse_iterator { typedef reverse_iterator< - BOOST_DEDUCED_TYPENAME const_iterator_of::type > type; + BOOST_DEDUCED_TYPENAME range_const_iterator::type > type; }; } // namespace boost diff --git a/include/boost/range/detail/begin.hpp b/include/boost/range/detail/begin.hpp index 2d9ec7a..a53588a 100755 --- a/include/boost/range/detail/begin.hpp +++ b/include/boost/range/detail/begin.hpp @@ -30,7 +30,7 @@ namespace boost struct range_begin { template< typename C > - static BOOST_RANGE_DEDUCED_TYPENAME result_iterator_of::type fun( C& c ) + static BOOST_RANGE_DEDUCED_TYPENAME range_result_iterator::type fun( C& c ) { return c.begin(); }; @@ -44,7 +44,7 @@ namespace boost struct range_begin { template< typename P > - static BOOST_RANGE_DEDUCED_TYPENAME result_iterator_of

::type fun( const P& p ) + static BOOST_RANGE_DEDUCED_TYPENAME range_result_iterator

::type fun( const P& p ) { return p.first; } @@ -108,7 +108,7 @@ namespace boost } // namespace 'range_detail' template< typename C > - inline BOOST_DEDUCED_TYPENAME result_iterator_of::type + inline BOOST_DEDUCED_TYPENAME range_result_iterator::type begin( C& c ) { return range_detail::range_begin< BOOST_DEDUCED_TYPENAME range_detail::range::type >::fun( c ); diff --git a/include/boost/range/detail/const_iterator.hpp b/include/boost/range/detail/const_iterator.hpp index 503804d..177f213 100755 --- a/include/boost/range/detail/const_iterator.hpp +++ b/include/boost/range/detail/const_iterator.hpp @@ -111,7 +111,7 @@ namespace boost } template< typename C > - class const_iterator_of + class range_const_iterator { typedef BOOST_DEDUCED_TYPENAME range_detail::range::type c_type; public: diff --git a/include/boost/range/detail/difference_type.hpp b/include/boost/range/detail/difference_type.hpp index 36acfe1..c641516 100755 --- a/include/boost/range/detail/difference_type.hpp +++ b/include/boost/range/detail/difference_type.hpp @@ -108,7 +108,7 @@ namespace boost } template< typename C > - class difference_type_of + class range_difference { typedef BOOST_RANGE_DEDUCED_TYPENAME range_detail::range::type c_type; public: diff --git a/include/boost/range/detail/end.hpp b/include/boost/range/detail/end.hpp index 0872e95..f3c4633 100755 --- a/include/boost/range/detail/end.hpp +++ b/include/boost/range/detail/end.hpp @@ -30,7 +30,8 @@ namespace boost struct range_end { template< typename C > - static BOOST_RANGE_DEDUCED_TYPENAME result_iterator_of::type fun( C& c ) + static BOOST_RANGE_DEDUCED_TYPENAME range_result_iterator::type + fun( C& c ) { return c.end(); }; @@ -44,7 +45,8 @@ namespace boost struct range_end { template< typename P > - static BOOST_RANGE_DEDUCED_TYPENAME result_iterator_of

::type fun( const P& p ) + static BOOST_RANGE_DEDUCED_TYPENAME range_result_iterator

::type + fun( const P& p ) { return p.second; } @@ -129,10 +131,10 @@ namespace boost } // namespace 'range_detail' template< typename C > - inline BOOST_DEDUCED_TYPENAME result_iterator_of::type + inline BOOST_DEDUCED_TYPENAME range_result_iterator::type end( C& c ) { - return range_detail::range_end< BOOST_DEDUCED_TYPENAME range_detail::range::type >::fun( c ); + return range_detail::range_end< BOOST_DEDUCED_TYPENAME range_detail::range::type >::fun( c ); } } // namespace 'boost' diff --git a/include/boost/range/detail/iterator.hpp b/include/boost/range/detail/iterator.hpp index 506778c..adedf27 100755 --- a/include/boost/range/detail/iterator.hpp +++ b/include/boost/range/detail/iterator.hpp @@ -110,7 +110,7 @@ namespace boost } template< typename C > - class iterator_of + class range_iterator { typedef BOOST_DEDUCED_TYPENAME range_detail::range::type c_type; public: diff --git a/include/boost/range/detail/size.hpp b/include/boost/range/detail/size.hpp index eaf27f7..c53946e 100755 --- a/include/boost/range/detail/size.hpp +++ b/include/boost/range/detail/size.hpp @@ -22,14 +22,14 @@ namespace boost namespace range_detail { template< typename T > - struct range_size; + struct range_size_; ////////////////////////////////////////////////////////////////////// // default ////////////////////////////////////////////////////////////////////// template<> - struct range_size + struct range_size_ { template< typename C > static BOOST_RANGE_DEDUCED_TYPENAME C::size_type fun( const C& c ) @@ -43,10 +43,11 @@ namespace boost ////////////////////////////////////////////////////////////////////// template<> - struct range_size + struct range_size_ { template< typename P > - static BOOST_RANGE_DEDUCED_TYPENAME size_type_of

::type fun( const P& p ) + static BOOST_RANGE_DEDUCED_TYPENAME range_size

::type + fun( const P& p ) { return std::distance( p.first, p.second ); } @@ -57,30 +58,30 @@ namespace boost ////////////////////////////////////////////////////////////////////// template<> - struct range_size + struct range_size_ { template< typename T, std::size_t sz > - static std::size_t fun( T BOOST_ARRAY_REF[sz] ) + static std::size_t fun( T BOOST_RANGE_ARRAY_REF()[sz] ) { return sz; } }; template<> - struct range_size + struct range_size_ { template< typename T, std::size_t sz > - static std::size_t fun( T BOOST_ARRAY_REF[sz] ) + static std::size_t fun( T BOOST_RANGE_ARRAY_REF()[sz] ) { return boost::range_detail::array_size( array ); } }; template<> - struct range_size + struct range_size_ { template< typename T, std::size_t sz > - static std::size_t fun( T BOOST_ARRAY_REF[sz] ) + static std::size_t fun( T BOOST_RANGE_ARRAY_REF()[sz] ) { return boost::range_detail::array_size( array ); } @@ -91,7 +92,7 @@ namespace boost ////////////////////////////////////////////////////////////////////// template<> - struct range_size + struct range_size_ { static std::size_t fun( const char* s ) { @@ -100,7 +101,7 @@ namespace boost }; template<> - struct range_size + struct range_size_ { static std::size_t fun( const char* s ) { @@ -109,7 +110,7 @@ namespace boost }; template<> - struct range_size + struct range_size_ { static std::size_t fun( const wchar_t* s ) { @@ -118,7 +119,7 @@ namespace boost }; template<> - struct range_size + struct range_size_ { static std::size_t fun( const wchar_t* s ) { @@ -130,10 +131,10 @@ namespace boost template< typename C > - BOOST_RANGE_DEDUCED_TYPENAME size_type_of::type + BOOST_RANGE_DEDUCED_TYPENAME range_size::type size( const C& c ) { - return range_detail::range_size< BOOST_RANGE_DEDUCED_TYPENAME range_detail::range::type >::fun( c ); + return range_detail::range_size_< BOOST_RANGE_DEDUCED_TYPENAME range_detail::range::type >::fun( c ); } } // namespace 'boost' diff --git a/include/boost/range/detail/size_type.hpp b/include/boost/range/detail/size_type.hpp index 3d5fa8c..ea2df02 100755 --- a/include/boost/range/detail/size_type.hpp +++ b/include/boost/range/detail/size_type.hpp @@ -102,12 +102,11 @@ namespace boost { typedef std::size_t type; }; - }; - + }; } template< typename C > - class size_type_of + class range_size { typedef BOOST_DEDUCED_TYPENAME range_detail::range::type c_type; public: diff --git a/include/boost/range/detail/value_type.hpp b/include/boost/range/detail/value_type.hpp index d8be495..490bce8 100755 --- a/include/boost/range/detail/value_type.hpp +++ b/include/boost/range/detail/value_type.hpp @@ -12,6 +12,7 @@ #define BOOST_RANGE_DETAIL_VALUE_TYPE_HPP #include +#include #include ////////////////////////////////////////////////////////////////////////////// @@ -51,7 +52,7 @@ namespace boost template< typename T > struct pts { - typedef void /*dummy*/ type; + typedef BOOST_DEDUCED_TYPENAME boost::remove_bounds::type type; }; }; @@ -108,7 +109,7 @@ namespace boost } template< typename C > - class value_type_of + class range_value { typedef BOOST_DEDUCED_TYPENAME range_detail::range::type c_type; public: diff --git a/include/boost/range/difference_type.hpp b/include/boost/range/difference_type.hpp index 6a82f69..27f71d3 100755 --- a/include/boost/range/difference_type.hpp +++ b/include/boost/range/difference_type.hpp @@ -32,7 +32,7 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename C > - struct difference_type_of + struct range_difference { typedef BOOST_DEDUCED_TYPENAME C::difference_type type; }; @@ -42,14 +42,14 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename Iterator > - struct difference_type_of< std::pair > + struct range_difference< std::pair > { typedef BOOST_DEDUCED_TYPENAME iterator_difference::type type; }; template< typename Iterator > - struct difference_type_of< const std::pair > + struct range_difference< const std::pair > { typedef BOOST_DEDUCED_TYPENAME iterator_difference::type type; @@ -61,13 +61,13 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename T, std::size_t sz > - struct difference_type_of< T[sz] > + struct range_difference< T[sz] > { typedef std::ptrdiff_t type; }; template< typename T, std::size_t sz > - struct difference_type_of< const T[sz] > + struct range_difference< const T[sz] > { typedef std::ptrdiff_t type; }; @@ -77,25 +77,25 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template<> - struct difference_type_of< char* > + struct range_difference< char* > { typedef std::ptrdiff_t type; }; template<> - struct difference_type_of< wchar_t* > + struct range_difference< wchar_t* > { typedef std::ptrdiff_t type; }; template<> - struct difference_type_of< const char* > + struct range_difference< const char* > { typedef std::ptrdiff_t type; }; template<> - struct difference_type_of< const wchar_t* > + struct range_difference< const wchar_t* > { typedef std::ptrdiff_t type; }; diff --git a/include/boost/range/empty.hpp b/include/boost/range/empty.hpp index 3be81b2..c19490b 100755 --- a/include/boost/range/empty.hpp +++ b/include/boost/range/empty.hpp @@ -25,7 +25,7 @@ namespace boost { -namespace range +namespace range_detail { ////////////////////////////////////////////////////////////////////// @@ -52,16 +52,16 @@ namespace range return s == 0 || s[0] == 0; } -} // namespace 'range' +} // namespace 'range_detail' template< class T > inline bool empty( const T& r ) { #if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - using range::empty; + using range_detail::empty; return empty( r ); #else - return range::empty( r ); + return range_detail::empty( r ); #endif } diff --git a/include/boost/range/end.hpp b/include/boost/range/end.hpp index d9d9fb3..874a50c 100755 --- a/include/boost/range/end.hpp +++ b/include/boost/range/end.hpp @@ -27,7 +27,7 @@ namespace boost { -namespace range +namespace range_detail { ////////////////////////////////////////////////////////////////////// @@ -35,14 +35,14 @@ namespace range ////////////////////////////////////////////////////////////////////// template< typename C > - inline BOOST_DEDUCED_TYPENAME const_iterator_of::type + inline BOOST_DEDUCED_TYPENAME range_const_iterator::type end( const C& c ) { return c.end(); } template< typename C > - inline BOOST_DEDUCED_TYPENAME iterator_of::type + inline BOOST_DEDUCED_TYPENAME range_iterator::type end( C& c ) { return c.end(); @@ -104,27 +104,27 @@ namespace range return range_detail::str_end( s ); } -} // namespace 'range' +} // namespace 'range_detail' template< class T > -inline BOOST_DEDUCED_TYPENAME iterator_of::type end( T& r ) +inline BOOST_DEDUCED_TYPENAME range_iterator::type end( T& r ) { #if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - using range::end; + using range_detail::end; return end( r ); #else - return range::end( r ); + return range_detail::end( r ); #endif } template< class T > -inline BOOST_DEDUCED_TYPENAME const_iterator_of::type end( const T& r ) +inline BOOST_DEDUCED_TYPENAME range_const_iterator::type end( const T& r ) { #if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - using range::end; + using range_detail::end; return end( r ); #else - return range::end( r ); + return range_detail::end( r ); #endif } diff --git a/include/boost/range/iterator.hpp b/include/boost/range/iterator.hpp index 6e5f6e1..67b5948 100755 --- a/include/boost/range/iterator.hpp +++ b/include/boost/range/iterator.hpp @@ -32,7 +32,7 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename C > - struct iterator_of + struct range_iterator { typedef BOOST_DEDUCED_TYPENAME C::iterator type; }; @@ -42,13 +42,13 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename Iterator > - struct iterator_of< std::pair > + struct range_iterator< std::pair > { typedef Iterator type; }; template< typename Iterator > - struct iterator_of< const std::pair > + struct range_iterator< const std::pair > { typedef Iterator type; }; @@ -58,13 +58,13 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename T, std::size_t sz > - struct iterator_of< T[sz] > + struct range_iterator< T[sz] > { typedef T* type; }; template< typename T, std::size_t sz > - struct iterator_of< const T[sz] > + struct range_iterator< const T[sz] > { typedef const T* type; }; @@ -74,25 +74,25 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template<> - struct iterator_of< char* > + struct range_iterator< char* > { typedef char* type; }; template<> - struct iterator_of< wchar_t* > + struct range_iterator< wchar_t* > { typedef wchar_t* type; }; template<> - struct iterator_of< const char* > + struct range_iterator< const char* > { typedef const char* type; }; template<> - struct iterator_of< const wchar_t* > + struct range_iterator< const wchar_t* > { typedef const wchar_t* type; }; diff --git a/include/boost/range/iterator_range.hpp b/include/boost/range/iterator_range.hpp index 2d2e9d6..1ab488e 100755 --- a/include/boost/range/iterator_range.hpp +++ b/include/boost/range/iterator_range.hpp @@ -221,10 +221,10 @@ namespace boost { #ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING template< typename Range > - inline iterator_range< BOOST_DEDUCED_TYPENAME result_iterator_of::type > + inline iterator_range< BOOST_DEDUCED_TYPENAME range_result_iterator::type > make_iterator_range( Range& r ) { - return iterator_range< BOOST_DEDUCED_TYPENAME result_iterator_of::type > + return iterator_range< BOOST_DEDUCED_TYPENAME range_result_iterator::type > ( begin( r ), end( r ) ); } @@ -235,18 +235,18 @@ namespace boost { and end iterators. */ template< class ForwardRange > - inline iterator_range< BOOST_DEDUCED_TYPENAME iterator_of::type > + inline iterator_range< BOOST_DEDUCED_TYPENAME range_iterator::type > make_iterator_range( ForwardRange& r ) { - return iterator_range< BOOST_DEDUCED_TYPENAME iterator_of::type > + return iterator_range< BOOST_DEDUCED_TYPENAME range_iterator::type > ( r ); } template< class ForwardRange > - inline iterator_range< BOOST_DEDUCED_TYPENAME const_iterator_of::type > + inline iterator_range< BOOST_DEDUCED_TYPENAME range_const_iterator::type > make_iterator_range( const ForwardRange& r ) { - return iterator_range< BOOST_DEDUCED_TYPENAME const_iterator_of::type > + return iterator_range< BOOST_DEDUCED_TYPENAME range_const_iterator::type > ( r ); } #endif diff --git a/include/boost/range/rbegin.hpp b/include/boost/range/rbegin.hpp index 5b13ddb..52bfd45 100755 --- a/include/boost/range/rbegin.hpp +++ b/include/boost/range/rbegin.hpp @@ -26,26 +26,26 @@ namespace boost #ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING template< class C > -inline BOOST_DEDUCED_TYPENAME reverse_result_iterator_of::type +inline BOOST_DEDUCED_TYPENAME range_reverse_result_iterator::type rbegin( C& c ) { - return BOOST_DEDUCED_TYPENAME reverse_result_iterator_of::type( end( c ) ); + return BOOST_DEDUCED_TYPENAME range_reverse_result_iterator::type( end( c ) ); } #else template< class C > -inline BOOST_DEDUCED_TYPENAME reverse_iterator_of::type +inline BOOST_DEDUCED_TYPENAME range_reverse_iterator::type rbegin( C& c ) { - return BOOST_DEDUCED_TYPENAME reverse_iterator_of::type( end( c ) ); + return BOOST_DEDUCED_TYPENAME range_reverse_iterator::type( end( c ) ); } template< class C > -inline BOOST_DEDUCED_TYPENAME const_reverse_iterator_of::type +inline BOOST_DEDUCED_TYPENAME range_const_reverse_iterator::type rbegin( const C& c ) { - return BOOST_DEDUCED_TYPENAME const_reverse_iterator_of::type( end( c ) ); + return BOOST_DEDUCED_TYPENAME range_const_reverse_iterator::type( end( c ) ); } #endif diff --git a/include/boost/range/rend.hpp b/include/boost/range/rend.hpp index b913a98..4e42422 100755 --- a/include/boost/range/rend.hpp +++ b/include/boost/range/rend.hpp @@ -26,26 +26,26 @@ namespace boost #ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING template< class C > -inline BOOST_DEDUCED_TYPENAME reverse_result_iterator_of::type +inline BOOST_DEDUCED_TYPENAME range_reverse_result_iterator::type rend( C& c ) { - return BOOST_DEDUCED_TYPENAME reverse_result_iterator_of::type( begin( c ) ); + return BOOST_DEDUCED_TYPENAME range_reverse_result_iterator::type( begin( c ) ); } #else template< class C > -inline BOOST_DEDUCED_TYPENAME reverse_iterator_of::type +inline BOOST_DEDUCED_TYPENAME range_reverse_iterator::type rend( C& c ) { - return BOOST_DEDUCED_TYPENAME reverse_iterator_of::type( begin( c ) ); + return BOOST_DEDUCED_TYPENAME range_reverse_iterator::type( begin( c ) ); } template< class C > -inline BOOST_DEDUCED_TYPENAME const_reverse_iterator_of::type +inline BOOST_DEDUCED_TYPENAME range_const_reverse_iterator::type rend( const C& c ) { - return BOOST_DEDUCED_TYPENAME const_reverse_iterator_of::type( begin( c ) ); + return BOOST_DEDUCED_TYPENAME range_const_reverse_iterator::type( begin( c ) ); } #endif diff --git a/include/boost/range/result_iterator.hpp b/include/boost/range/result_iterator.hpp index e6cdd03..86e71cd 100755 --- a/include/boost/range/result_iterator.hpp +++ b/include/boost/range/result_iterator.hpp @@ -28,12 +28,12 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename C > - struct result_iterator_of + struct range_result_iterator { typedef BOOST_RANGE_DEDUCED_TYPENAME mpl::if_< BOOST_DEDUCED_TYPENAME is_const::type, - BOOST_DEDUCED_TYPENAME const_iterator_of::type, - BOOST_DEDUCED_TYPENAME iterator_of::type >::type type; + BOOST_DEDUCED_TYPENAME range_const_iterator::type, + BOOST_DEDUCED_TYPENAME range_iterator::type >::type type; }; } // namespace boost diff --git a/include/boost/range/reverse_iterator.hpp b/include/boost/range/reverse_iterator.hpp index 299d57c..f8e9221 100755 --- a/include/boost/range/reverse_iterator.hpp +++ b/include/boost/range/reverse_iterator.hpp @@ -27,10 +27,10 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename C > - struct reverse_iterator_of + struct range_reverse_iterator { typedef reverse_iterator< - BOOST_DEDUCED_TYPENAME iterator_of::type > type; + BOOST_DEDUCED_TYPENAME range_iterator::type > type; }; diff --git a/include/boost/range/reverse_result_iterator.hpp b/include/boost/range/reverse_result_iterator.hpp index 2943d23..715ed53 100755 --- a/include/boost/range/reverse_result_iterator.hpp +++ b/include/boost/range/reverse_result_iterator.hpp @@ -26,10 +26,10 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename C > - struct reverse_result_iterator_of + struct range_reverse_result_iterator { typedef reverse_iterator< - BOOST_DEDUCED_TYPENAME result_iterator_of::type > type; + BOOST_DEDUCED_TYPENAME range_result_iterator::type > type; }; } // namespace boost diff --git a/include/boost/range/size.hpp b/include/boost/range/size.hpp index 05ec975..04e0fbe 100755 --- a/include/boost/range/size.hpp +++ b/include/boost/range/size.hpp @@ -29,7 +29,7 @@ namespace boost { -namespace range +namespace range_detail { ////////////////////////////////////////////////////////////////////// @@ -86,13 +86,13 @@ namespace range } // namespace 'range' template< class T > -inline BOOST_DEDUCED_TYPENAME size_type_of::type size( const T& r ) +inline BOOST_DEDUCED_TYPENAME range_size::type size( const T& r ) { #if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - using range::size; + using range_detail::size; return size( r ); #else - return range::size( r ); + return range_detail::size( r ); #endif } diff --git a/include/boost/range/size_type.hpp b/include/boost/range/size_type.hpp index 0288822..cbc7b83 100755 --- a/include/boost/range/size_type.hpp +++ b/include/boost/range/size_type.hpp @@ -31,7 +31,7 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename C > - struct size_type_of + struct range_size { typedef BOOST_DEDUCED_TYPENAME C::size_type type; }; @@ -41,13 +41,13 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename Iterator > - struct size_type_of< std::pair > + struct range_size< std::pair > { typedef std::size_t type; }; template< typename Iterator > - struct size_type_of< const std::pair > + struct range_size< const std::pair > { typedef std::size_t type; }; @@ -57,13 +57,13 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename T, std::size_t sz > - struct size_type_of< T[sz] > + struct range_size< T[sz] > { typedef std::size_t type; }; template< typename T, std::size_t sz > - struct size_type_of< const T[sz] > + struct range_size< const T[sz] > { typedef std::size_t type; }; @@ -73,25 +73,25 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template<> - struct size_type_of< char* > + struct range_size< char* > { typedef std::size_t type; }; template<> - struct size_type_of< wchar_t* > + struct range_size< wchar_t* > { typedef std::size_t type; }; template<> - struct size_type_of< const char* > + struct range_size< const char* > { typedef std::size_t type; }; template<> - struct size_type_of< const wchar_t* > + struct range_size< const wchar_t* > { typedef std::size_t type; }; diff --git a/include/boost/range/sub_range.hpp b/include/boost/range/sub_range.hpp index 33fba98..0272fbf 100755 --- a/include/boost/range/sub_range.hpp +++ b/include/boost/range/sub_range.hpp @@ -22,17 +22,17 @@ namespace boost { template< class ForwardRange > - class sub_range : public iterator_range< BOOST_DEDUCED_TYPENAME result_iterator_of::type > + class sub_range : public iterator_range< BOOST_DEDUCED_TYPENAME range_result_iterator::type > { - typedef BOOST_DEDUCED_TYPENAME result_iterator_of::type iterator_t; + typedef BOOST_DEDUCED_TYPENAME range_result_iterator::type iterator_t; typedef iterator_range< iterator_t > base; public: - typedef BOOST_DEDUCED_TYPENAME value_type_of::type value_type; - typedef BOOST_DEDUCED_TYPENAME result_iterator_of::type iterator; - typedef BOOST_DEDUCED_TYPENAME const_iterator_of::type const_iterator; - typedef BOOST_DEDUCED_TYPENAME difference_type_of::type difference_type; - typedef BOOST_DEDUCED_TYPENAME size_type_of::type size_type; + typedef BOOST_DEDUCED_TYPENAME range_value::type value_type; + typedef BOOST_DEDUCED_TYPENAME range_result_iterator::type iterator; + typedef BOOST_DEDUCED_TYPENAME range_const_iterator::type const_iterator; + typedef BOOST_DEDUCED_TYPENAME range_difference::type difference_type; + typedef BOOST_DEDUCED_TYPENAME range_size::type size_type; public: template< class ForwardRange2 > diff --git a/include/boost/range/value_type.hpp b/include/boost/range/value_type.hpp index 7f38602..137b410 100755 --- a/include/boost/range/value_type.hpp +++ b/include/boost/range/value_type.hpp @@ -33,7 +33,7 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename C > - struct value_type_of + struct range_value { typedef BOOST_DEDUCED_TYPENAME C::value_type type; }; @@ -43,7 +43,7 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename Iterator > - struct value_type_of< std::pair > + struct range_value< std::pair > { typedef BOOST_DEDUCED_TYPENAME iterator_value::type type; @@ -51,7 +51,7 @@ namespace boost template< typename Iterator > - struct value_type_of< const std::pair > + struct range_value< const std::pair > { typedef BOOST_DEDUCED_TYPENAME iterator_value::type type; @@ -62,13 +62,13 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template< typename T, std::size_t sz > - struct value_type_of< T[sz] > + struct range_value< T[sz] > { typedef T type; }; template< typename T, std::size_t sz > - struct value_type_of< const T[sz] > + struct range_value< const T[sz] > { typedef const T type; }; @@ -78,25 +78,25 @@ namespace boost ////////////////////////////////////////////////////////////////////////// template<> - struct value_type_of< char* > + struct range_value< char* > { typedef char type; }; template<> - struct value_type_of< wchar_t* > + struct range_value< wchar_t* > { typedef wchar_t type; }; template<> - struct value_type_of< const char* > + struct range_value< const char* > { typedef const char type; }; template<> - struct value_type_of< const wchar_t* > + struct range_value< const wchar_t* > { typedef const wchar_t type; }; diff --git a/test/Jamfile b/test/Jamfile index 0c552c7..f02dd93 100755 --- a/test/Jamfile +++ b/test/Jamfile @@ -82,7 +82,7 @@ test-suite range : adl_conformance ] [ run - adl_conformance_no_using_declaration.cpp + adl_conformance_no_using.cpp : : : : adl_conformance_no_using_declaration diff --git a/test/algorithm_example.cpp b/test/algorithm_example.cpp index 41014b7..a684da1 100755 --- a/test/algorithm_example.cpp +++ b/test/algorithm_example.cpp @@ -15,7 +15,7 @@ # pragma warn -8057 // unused argument argc/argv in Boost.Test #endif -#include +#include #include #include #include @@ -30,14 +30,14 @@ namespace // example: extrating bounds in a generic algorithm // template< typename Range, typename T > - inline typename boost::iterator_of::type + inline typename boost::range_iterator::type find( Range& c, const T& value ) { return std::find( boost::begin( c ), boost::end( c ), value ); } template< typename Range, typename T > - inline typename boost::const_iterator_of::type + inline typename boost::range_const_iterator::type find( const Range& c, const T& value ) { return std::find( boost::begin( c ), boost::end( c ), value ); @@ -47,10 +47,10 @@ namespace // replace first value and return its index // template< class Range, class T > - inline typename boost::size_type_of< Range >::type + inline typename boost::range_size::type my_generic_replace( Range& c, const T& value, const T& replacement ) { - typename boost::iterator_of::type found = find( c, value ); + typename boost::range_iterator::type found = find( c, value ); if( found != boost::end( c ) ) *found = replacement; diff --git a/test/array.cpp b/test/array.cpp index 093a775..953a57f 100755 --- a/test/array.cpp +++ b/test/array.cpp @@ -42,21 +42,21 @@ void check_array() // BOOST_RANGE_NO_STATIC_ASSERT #if !defined( __BORLANDC__ ) || ( _MSC_VER <= 1200 ) #else - BOOST_STATIC_ASSERT(( is_same< value_type_of::type, int >::value )); - BOOST_STATIC_ASSERT(( is_same< iterator_of::type, int* >::value )); - BOOST_STATIC_ASSERT(( is_same< const_iterator_of::type, const int* >::value )); - BOOST_STATIC_ASSERT(( is_same< difference_type_of::type, std::ptrdiff_t >::value )); - BOOST_STATIC_ASSERT(( is_same< size_type_of::type, std::size_t >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, int* >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, const int* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_value::type, int >::value )); + BOOST_STATIC_ASSERT(( is_same< range_iterator::type, int* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_const_iterator::type, const int* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_difference::type, std::ptrdiff_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_size::type, std::size_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, int* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, const int* >::value )); - BOOST_STATIC_ASSERT(( is_same< value_type_of::type, const int >::value )); - BOOST_STATIC_ASSERT(( is_same< iterator_of::type, const int* >::value )); - BOOST_STATIC_ASSERT(( is_same< const_iterator_of::type, const int* >::value )); - BOOST_STATIC_ASSERT(( is_same< difference_type_of::type, std::ptrdiff_t >::value )); - BOOST_STATIC_ASSERT(( is_same< size_type_of::type, std::size_t >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, const int* >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, const int* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_value::type, const int >::value )); + BOOST_STATIC_ASSERT(( is_same< range_iterator::type, const int* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_const_iterator::type, const int* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_difference::type, std::ptrdiff_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_size::type, std::size_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, const int* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, const int* >::value )); #endif BOOST_CHECK_EQUAL( begin( my_array ), my_array ); diff --git a/test/iterator_pair.cpp b/test/iterator_pair.cpp index 11928a2..97d2a07 100755 --- a/test/iterator_pair.cpp +++ b/test/iterator_pair.cpp @@ -41,25 +41,25 @@ void check_iterator_pair() const_pair_tt constness_pair( pair ); - BOOST_STATIC_ASSERT(( is_same< value_type_of::type, + BOOST_STATIC_ASSERT(( is_same< range_value::type, detail::iterator_traits::value_type>::value )); - BOOST_STATIC_ASSERT(( is_same< iterator_of::type, pair_t::first_type >::value )); - BOOST_STATIC_ASSERT(( is_same< const_iterator_of::type, pair_t::first_type >::value )); - BOOST_STATIC_ASSERT(( is_same< difference_type_of::type, + BOOST_STATIC_ASSERT(( is_same< range_iterator::type, pair_t::first_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_const_iterator::type, pair_t::first_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_difference::type, detail::iterator_traits::difference_type >::value )); - BOOST_STATIC_ASSERT(( is_same< size_type_of::type, std::size_t >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, pair_t::first_type >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, const_pair_t::first_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_size::type, std::size_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, pair_t::first_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, const_pair_t::first_type >::value )); - BOOST_STATIC_ASSERT(( is_same< value_type_of::type, + BOOST_STATIC_ASSERT(( is_same< range_value::type, detail::iterator_traits::value_type>::value )); - BOOST_STATIC_ASSERT(( is_same< iterator_of::type, const_pair_tt::first_type >::value )); - BOOST_STATIC_ASSERT(( is_same< const_iterator_of::type, const_pair_tt::first_type >::value )); - BOOST_STATIC_ASSERT(( is_same< difference_type_of::type, + BOOST_STATIC_ASSERT(( is_same< range_iterator::type, const_pair_tt::first_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_const_iterator::type, const_pair_tt::first_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_difference::type, detail::iterator_traits::difference_type >::value )); - BOOST_STATIC_ASSERT(( is_same< size_type_of::type, std::size_t >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, const_pair_tt::first_type >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, const_pair_tt::first_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_size::type, std::size_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, const_pair_tt::first_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, const_pair_tt::first_type >::value )); BOOST_CHECK( begin( pair ) == pair.first ); BOOST_CHECK( end( pair ) == pair.second ); diff --git a/test/reversible_range.cpp b/test/reversible_range.cpp index 833914d..c88d160 100755 --- a/test/reversible_range.cpp +++ b/test/reversible_range.cpp @@ -32,11 +32,11 @@ using namespace std; void check_iterator() { - typedef vector vec_t; - typedef vec_t::iterator iterator; - typedef pair pair_t; - typedef reverse_iterator_of::type rev_iterator; - typedef pair rev_pair_t; + typedef vector vec_t; + typedef vec_t::iterator iterator; + typedef pair pair_t; + typedef range_reverse_iterator::type rev_iterator; + typedef pair rev_pair_t; vec_t vec; pair_t p = make_pair( vec.begin(), vec.end() ); @@ -50,8 +50,8 @@ void check_iterator() wchar_t wa[] = L"mutable"; const wchar_t cwa[]= L"not mutable"; - BOOST_CHECK( rbegin( vec ) == reverse_iterator_of::type( vec.end() ) ); - BOOST_CHECK( rend( vec ) == reverse_iterator_of::type( vec.begin() ) ); + BOOST_CHECK( rbegin( vec ) == range_reverse_iterator::type( vec.end() ) ); + BOOST_CHECK( rend( vec ) == range_reverse_iterator::type( vec.begin() ) ); BOOST_CHECK( distance( rbegin( vec ), rend( vec ) ) == distance( begin( vec ), end( vec ) ) ); BOOST_CHECK( rbegin( p ) == begin( rp ) ); diff --git a/test/std_container.cpp b/test/std_container.cpp index 836fe02..7bb40f5 100755 --- a/test/std_container.cpp +++ b/test/std_container.cpp @@ -34,19 +34,19 @@ void check_std_container() vec.push_back( 3 ); vec.push_back( 4 ); const vec_t cvec( vec ); - BOOST_STATIC_ASSERT(( is_same< value_type_of::type, vec_t::value_type >::value )); - BOOST_STATIC_ASSERT(( is_same< iterator_of::type, vec_t::iterator >::value )); - BOOST_STATIC_ASSERT(( is_same< const_iterator_of::type, vec_t::const_iterator >::value )); - BOOST_STATIC_ASSERT(( is_same< difference_type_of::type, vec_t::difference_type >::value )); - BOOST_STATIC_ASSERT(( is_same< size_type_of::type, vec_t::size_type >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, vec_t::iterator >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, vec_t::const_iterator >::value )); + BOOST_STATIC_ASSERT(( is_same< range_value::type, vec_t::value_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_iterator::type, vec_t::iterator >::value )); + BOOST_STATIC_ASSERT(( is_same< range_const_iterator::type, vec_t::const_iterator >::value )); + BOOST_STATIC_ASSERT(( is_same< range_difference::type, vec_t::difference_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_size::type, vec_t::size_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, vec_t::iterator >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, vec_t::const_iterator >::value )); - BOOST_STATIC_ASSERT(( is_same< value_type_of::type, vec_t::value_type >::value )); - BOOST_STATIC_ASSERT(( is_same< iterator_of::type, vec_t::iterator >::value )); - BOOST_STATIC_ASSERT(( is_same< const_iterator_of::type, vec_t::const_iterator >::value )); - BOOST_STATIC_ASSERT(( is_same< difference_type_of::type, vec_t::difference_type >::value )); - BOOST_STATIC_ASSERT(( is_same< size_type_of::type, vec_t::size_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_value::type, vec_t::value_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_iterator::type, vec_t::iterator >::value )); + BOOST_STATIC_ASSERT(( is_same< range_const_iterator::type, vec_t::const_iterator >::value )); + BOOST_STATIC_ASSERT(( is_same< range_difference::type, vec_t::difference_type >::value )); + BOOST_STATIC_ASSERT(( is_same< range_size::type, vec_t::size_type >::value )); BOOST_CHECK( begin( vec ) == vec.begin() ); BOOST_CHECK( end( vec ) == vec.end() ); diff --git a/test/string.cpp b/test/string.cpp index 7f4c3dc..3795276 100755 --- a/test/string.cpp +++ b/test/string.cpp @@ -28,14 +28,14 @@ #include template< typename Container, typename T > -BOOST_DEDUCED_TYPENAME boost::iterator_of::type +BOOST_DEDUCED_TYPENAME boost::range_iterator::type find( Container& c, T value ) { return std::find( boost::begin( c ), boost::end( c ), value ); } template< typename Container, typename T > -BOOST_DEDUCED_TYPENAME boost::const_iterator_of::type +BOOST_DEDUCED_TYPENAME boost::range_const_iterator::type find( const Container& c, T value ) { return std::find( boost::begin( c ), boost::end( c ), value ); @@ -59,28 +59,28 @@ void check_char() const unsigned my_string_length = 14; - BOOST_STATIC_ASSERT(( is_same< value_type_of::type, + BOOST_STATIC_ASSERT(( is_same< range_value::type, detail::iterator_traits::value_type>::value )); - BOOST_STATIC_ASSERT(( is_same< iterator_of::type, char_iterator_t >::value )); - BOOST_STATIC_ASSERT(( is_same< const_iterator_of::type, const char* >::value )); - BOOST_STATIC_ASSERT(( is_same< difference_type_of::type, + BOOST_STATIC_ASSERT(( is_same< range_iterator::type, char_iterator_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_const_iterator::type, const char* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_difference::type, ::std::ptrdiff_t >::value )); - BOOST_STATIC_ASSERT(( is_same< size_type_of::type, std::size_t >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, char_iterator_t >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, const char* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_size::type, std::size_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, char_iterator_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, const char* >::value )); // // note: why does is_same< result_iterator::type, const char* >::value // fail?!? - BOOST_STATIC_ASSERT(( is_same< value_type_of::type, + BOOST_STATIC_ASSERT(( is_same< range_value::type, char>::value )); - BOOST_STATIC_ASSERT(( is_same< iterator_of::type, char* >::value )); - BOOST_STATIC_ASSERT(( is_same< const_iterator_of::type, const char* >::value )); - BOOST_STATIC_ASSERT(( is_same< difference_type_of::type, + BOOST_STATIC_ASSERT(( is_same< range_iterator::type, char* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_const_iterator::type, const char* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_difference::type, ::std::ptrdiff_t >::value )); - BOOST_STATIC_ASSERT(( is_same< size_type_of::type, std::size_t >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, char* >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, const char* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_size::type, std::size_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, char* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, const char* >::value )); BOOST_CHECK_EQUAL( begin( char_s ), char_s ); std::size_t sz = size( char_s ); @@ -90,8 +90,8 @@ void check_char() BOOST_CHECK_EQUAL( sz, std::char_traits::length( char_s ) ); BOOST_CHECK_EQUAL( begin( my_string ), my_string ); - iterator_of::type end2 = begin( my_string ) + size( my_string ); - iterator_of::type end3 = end( my_string ); + range_iterator::type end2 = begin( my_string ) + size( my_string ); + range_iterator::type end3 = end( my_string ); BOOST_CHECK_EQUAL( end3, end2 ); BOOST_CHECK_EQUAL( empty( my_string ), (my_string == 0 || my_string[0] == char()) ); BOOST_CHECK_EQUAL( size( my_string ), my_string_length ); @@ -118,15 +118,15 @@ void check_string() const wchar_t* char_ws = L"a wide string"; wchar_t my_wstring[] = L"another wide string"; - BOOST_STATIC_ASSERT(( is_same< value_type_of::type, + BOOST_STATIC_ASSERT(( is_same< range_value::type, detail::iterator_traits::value_type>::value )); - BOOST_STATIC_ASSERT(( is_same< iterator_of::type, wchar_iterator_t >::value )); - BOOST_STATIC_ASSERT(( is_same< const_iterator_of::type, const wchar_t* >::value )); - BOOST_STATIC_ASSERT(( is_same< difference_type_of::type, + BOOST_STATIC_ASSERT(( is_same< range_iterator::type, wchar_iterator_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_const_iterator::type, const wchar_t* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_difference::type, detail::iterator_traits::difference_type >::value )); - BOOST_STATIC_ASSERT(( is_same< size_type_of::type, std::size_t >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, wchar_iterator_t >::value )); - BOOST_STATIC_ASSERT(( is_same< result_iterator_of::type, const wchar_t* >::value )); + BOOST_STATIC_ASSERT(( is_same< range_size::type, std::size_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, wchar_iterator_t >::value )); + BOOST_STATIC_ASSERT(( is_same< range_result_iterator::type, const wchar_t* >::value )); std::size_t sz = size( char_ws ); BOOST_CHECK_EQUAL( begin( char_ws ), char_ws );