diff --git a/include/boost/range.hpp b/include/boost/range.hpp index 948c3d7..2aeb393 100755 --- a/include/boost/range.hpp +++ b/include/boost/range.hpp @@ -15,19 +15,9 @@ # pragma once #endif -#if _MSC_VER == 1300 // experiment - -#include -#include -#include - -#else - #include #include #include #include -#endif // _MSC_VER == 1300 // experiment - #endif diff --git a/include/boost/range/config.hpp b/include/boost/range/config.hpp index cf9e204..fc2693e 100644 --- a/include/boost/range/config.hpp +++ b/include/boost/range/config.hpp @@ -26,18 +26,14 @@ #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) # define BOOST_RANGE_DEDUCED_TYPENAME typename #else -# if BOOST_WORKAROUND(BOOST_MSVC, == 1300) && !defined(_MSC_EXTENSIONS) -# define BOOST_RANGE_DEDUCED_TYPENAME typename -# else -# define BOOST_RANGE_DEDUCED_TYPENAME BOOST_DEDUCED_TYPENAME -# endif +#define BOOST_RANGE_DEDUCED_TYPENAME BOOST_DEDUCED_TYPENAME #endif #ifdef BOOST_RANGE_NO_ARRAY_SUPPORT #error "macro already defined!" #endif -#if BOOST_WORKAROUND( BOOST_MSVC, < 1300 ) || BOOST_WORKAROUND( __MWERKS__, <= 0x3003 ) +#if BOOST_WORKAROUND( __MWERKS__, <= 0x3003 ) #define BOOST_RANGE_NO_ARRAY_SUPPORT 1 #endif diff --git a/include/boost/range/detail/begin.hpp b/include/boost/range/detail/begin.hpp index f3da732..1d9390f 100644 --- a/include/boost/range/detail/begin.hpp +++ b/include/boost/range/detail/begin.hpp @@ -15,9 +15,6 @@ #include #include #include -#if BOOST_WORKAROUND(BOOST_MSVC, < 1310) -# include -#endif namespace boost { @@ -62,19 +59,11 @@ namespace boost template<> struct range_begin { - #if !BOOST_WORKAROUND(BOOST_MSVC, < 1310) - template< typename T, std::size_t sz > - static T* fun( T BOOST_RANGE_ARRAY_REF()[sz] ) - { - return boost_range_array; - } - #else template static BOOST_RANGE_DEDUCED_TYPENAME range_value::type* fun(T& t) { return t; } - #endif }; } // namespace 'range_detail' diff --git a/include/boost/range/detail/end.hpp b/include/boost/range/detail/end.hpp index 8b5f35d..f2f7178 100644 --- a/include/boost/range/detail/end.hpp +++ b/include/boost/range/detail/end.hpp @@ -14,15 +14,9 @@ #include // BOOST_MSVC #include -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) -# include -#else -# include -# include -# include -# if BOOST_WORKAROUND(BOOST_MSVC, < 1310) -# include -# endif +#include +#include +#include namespace boost { @@ -68,19 +62,11 @@ namespace boost template<> struct range_end { - #if !BOOST_WORKAROUND(BOOST_MSVC, < 1310) - template< typename T, std::size_t sz > - static T* fun( T BOOST_RANGE_ARRAY_REF()[sz] ) - { - return boost::range_detail::array_end( boost_range_array ); - } - #else template static BOOST_RANGE_DEDUCED_TYPENAME remove_extent::type* fun(T& t) { return t + remove_extent::size; } - #endif }; } // namespace 'range_detail' @@ -97,5 +83,4 @@ namespace boost } // namespace 'boost' -# endif // VC6 #endif diff --git a/include/boost/range/detail/size.hpp b/include/boost/range/detail/size.hpp old mode 100755 new mode 100644 index fe52ba0..eec134c --- a/include/boost/range/detail/size.hpp +++ b/include/boost/range/detail/size.hpp @@ -14,16 +14,10 @@ #include // BOOST_MSVC #include -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) -# include -#else -# include -# include -# include -# if BOOST_WORKAROUND(BOOST_MSVC, == 1300) -# include -# endif -# include +#include +#include +#include +#include namespace boost { @@ -68,19 +62,11 @@ namespace boost template<> struct range_size_ { - #if !BOOST_WORKAROUND(BOOST_MSVC, <= 1300) - template< typename T, std::size_t sz > - static std::size_t fun( T BOOST_RANGE_ARRAY_REF()[sz] ) - { - return sz; - } - #else template static std::size_t fun(T& t) { return remove_extent::size; } - #endif }; template<> @@ -155,5 +141,4 @@ namespace boost } // namespace 'boost' -# endif #endif diff --git a/include/boost/range/detail/vc6/end.hpp b/include/boost/range/detail/vc6/end.hpp deleted file mode 100755 index 4f76af5..0000000 --- a/include/boost/range/detail/vc6/end.hpp +++ /dev/null @@ -1,170 +0,0 @@ -// Boost.Range library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/range/ -// - -#ifndef BOOST_RANGE_DETAIL_VC6_END_HPP -#define BOOST_RANGE_DETAIL_VC6_END_HPP - -#include -#include -#include -#include -#include - -namespace boost -{ - namespace range_detail - { - template< typename T > - struct range_end; - - ////////////////////////////////////////////////////////////////////// - // default - ////////////////////////////////////////////////////////////////////// - - template<> - struct range_end - { - template< typename C > - struct inner { - static BOOST_RANGE_DEDUCED_TYPENAME range_result_iterator::type - fun( C& c ) - { - return c.end(); - }; - }; - }; - - ////////////////////////////////////////////////////////////////////// - // pair - ////////////////////////////////////////////////////////////////////// - - template<> - struct range_end - { - template< typename P > - struct inner { - static BOOST_RANGE_DEDUCED_TYPENAME range_result_iterator

::type - fun( const P& p ) - { - return p.second; - } - }; - }; - - ////////////////////////////////////////////////////////////////////// - // array - ////////////////////////////////////////////////////////////////////// - - template<> - struct range_end - { - template< typename T > - struct inner { - static BOOST_DEDUCED_TYPENAME remove_extent::type* - fun(T& t) - { - return t + remove_extent::size; - } - }; - }; - - - template<> - struct range_end - { - template< typename T > - struct inner { - static BOOST_DEDUCED_TYPENAME remove_extent::type* - fun(T& t) - { - return t + remove_extent::size; - } - }; - }; - - template<> - struct range_end - { - template< typename T > - struct inner { - static BOOST_DEDUCED_TYPENAME remove_extent::type* - fun(T& t) - { - return t + remove_extent::size; - } - }; - }; - - ////////////////////////////////////////////////////////////////////// - // string - ////////////////////////////////////////////////////////////////////// - - template<> - struct range_end - { - template< typename T > - struct inner { - static char* fun( char* s ) - { - return boost::range_detail::str_end( s ); - } - }; - }; - - template<> - struct range_end - { - template< typename T > - struct inner { - static const char* fun( const char* s ) - { - return boost::range_detail::str_end( s ); - } - }; - }; - - template<> - struct range_end - { - template< typename T > - struct inner { - static wchar_t* fun( wchar_t* s ) - { - return boost::range_detail::str_end( s ); - } - }; - }; - - - template<> - struct range_end - { - template< typename T > - struct inner { - static const wchar_t* fun( const wchar_t* s ) - { - return boost::range_detail::str_end( s ); - } - }; - }; - - } // namespace 'range_detail' - - template< typename C > - inline BOOST_DEDUCED_TYPENAME range_result_iterator::type - end( C& c ) - { - return range_detail::range_end::type>::inner::fun( c ); - } - -} // namespace 'boost' - - -#endif diff --git a/include/boost/range/detail/vc6/size.hpp b/include/boost/range/detail/vc6/size.hpp deleted file mode 100755 index 39f559f..0000000 --- a/include/boost/range/detail/vc6/size.hpp +++ /dev/null @@ -1,166 +0,0 @@ -// Boost.Range library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/range/ -// - - -#ifndef BOOST_RANGE_DETAIL_VC6_SIZE_HPP -#define BOOST_RANGE_DETAIL_VC6_SIZE_HPP - -#include -#include -#include -#include -#include - -namespace boost -{ - namespace range_detail - { - template< typename T > - struct range_size_; - - ////////////////////////////////////////////////////////////////////// - // default - ////////////////////////////////////////////////////////////////////// - - template<> - struct range_size_ - { - template< typename C > - struct inner { - static BOOST_RANGE_DEDUCED_TYPENAME C::size_type fun( const C& c ) - { - return c.size(); - }; - }; - }; - - ////////////////////////////////////////////////////////////////////// - // pair - ////////////////////////////////////////////////////////////////////// - - template<> - struct range_size_ - { - template< typename P > - struct inner { - static BOOST_RANGE_DEDUCED_TYPENAME range_size

::type - fun( const P& p ) - { - return std::distance( p.first, p.second ); - } - }; - }; - - ////////////////////////////////////////////////////////////////////// - // array - ////////////////////////////////////////////////////////////////////// - - template<> - struct range_size_ - { - template - struct inner { - static std::size_t fun(T& t) - { - return remove_extent::size; - } - }; - }; - - template<> - struct range_size_ - { - template - struct inner { - static std::size_t fun(T& t) - { - return sizeof(T) / sizeof(T[0]); - } - }; - }; - - template<> - struct range_size_ - { - template - struct inner { - static std::size_t fun(T& t) - { - return sizeof(T) / sizeof(T[0]); - } - }; - }; - - ////////////////////////////////////////////////////////////////////// - // string - ////////////////////////////////////////////////////////////////////// - - template<> - struct range_size_ - { - template - struct inner { - static std::size_t fun( const char* s ) - { - return boost::range_detail::str_size( s ); - } - }; - }; - - template<> - struct range_size_ - { - template - struct inner { - static std::size_t fun( const char* s ) - { - return boost::range_detail::str_size( s ); - } - }; - }; - - template<> - struct range_size_ - { - template - struct inner { - static std::size_t fun( const wchar_t* s ) - { - return boost::range_detail::str_size( s ); - } - }; - }; - - template<> - struct range_size_ - { - template - struct inner { - static std::size_t fun( const wchar_t* s ) - { - return boost::range_detail::str_size( s ); - } - }; - }; - - } // namespace 'range_detail' - - - template< typename C > - BOOST_RANGE_DEDUCED_TYPENAME range_size::type - size( const C& c ) - { - return range_detail::range_size_::type>::inner::fun( c ); - } - -} // namespace 'boost' - - -#endif diff --git a/include/boost/range/iterator_range_core.hpp b/include/boost/range/iterator_range_core.hpp index 6e68992..f985641 100644 --- a/include/boost/range/iterator_range_core.hpp +++ b/include/boost/range/iterator_range_core.hpp @@ -207,14 +207,12 @@ namespace boost m_Begin( impl::adl_begin( r ) ), m_End( impl::adl_end( r ) ) {} - #if !BOOST_WORKAROUND(BOOST_MSVC, < 1300) this_type& operator=( const this_type& r ) { m_Begin = r.begin(); m_End = r.end(); return *this; } - #endif template< class Iterator > iterator_range& operator=( const iterator_range& r )