mirror of
https://github.com/boostorg/range.git
synced 2025-07-19 23:52:14 +02:00
*** empty log message ***
[SVN r24193]
This commit is contained in:
@ -40,22 +40,22 @@ void check_array()
|
|||||||
|
|
||||||
|
|
||||||
// BOOST_RANGE_NO_STATIC_ASSERT
|
// BOOST_RANGE_NO_STATIC_ASSERT
|
||||||
#if !defined( __BORLANDC__ ) || !( _MSC_VER <= 1300 )
|
#if !defined( __BORLANDC__ )
|
||||||
BOOST_STATIC_ASSERT(( is_same< value_type_of<array_t>::type, int >::value ));
|
BOOST_STATIC_ASSERT(( is_same< value_type_of<int[10]>::type, int >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< iterator_of<array_t>::type, int* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< iterator_of<int[10]>::type, int* >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< const_iterator_of<array_t>::type, const int* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< const_iterator_of<int[10]>::type, const int* >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< difference_type_of<array_t>::type, std::ptrdiff_t >::value ));
|
BOOST_STATIC_ASSERT(( is_same< difference_type_of<int[10]>::type, std::ptrdiff_t >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< size_type_of<array_t>::type, std::size_t >::value ));
|
BOOST_STATIC_ASSERT(( is_same< size_type_of<int[10]>::type, std::size_t >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<array_t>::type, int* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<int[10]>::type, int* >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<const array_t>::type, const int* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<const int[10]>::type, const int* >::value ));
|
||||||
|
|
||||||
BOOST_STATIC_ASSERT(( is_same< value_type_of<const array_t>::type, const int >::value ));
|
BOOST_STATIC_ASSERT(( is_same< value_type_of<const int[10]>::type, const int >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< iterator_of<const array_t>::type, const int* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< iterator_of<const int[10]>::type, const int* >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< const_iterator_of<const array_t>::type, const int* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< const_iterator_of<const int[10]>::type, const int* >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< difference_type_of<const array_t>::type, std::ptrdiff_t >::value ));
|
BOOST_STATIC_ASSERT(( is_same< difference_type_of<const int[10]>::type, std::ptrdiff_t >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< size_type_of<const array_t>::type, std::size_t >::value ));
|
BOOST_STATIC_ASSERT(( is_same< size_type_of<const int[10]>::type, std::size_t >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<const array_t>::type, const int* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<const int[10]>::type, const int* >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<const array_t>::type, const int* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<const int[10]>::type, const int* >::value ));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
BOOST_CHECK_EQUAL( begin( my_array ), my_array );
|
BOOST_CHECK_EQUAL( begin( my_array ), my_array );
|
||||||
|
@ -74,13 +74,13 @@ void check_char()
|
|||||||
|
|
||||||
BOOST_STATIC_ASSERT(( is_same< value_type_of<char_array_t>::type,
|
BOOST_STATIC_ASSERT(( is_same< value_type_of<char_array_t>::type,
|
||||||
char>::value ));
|
char>::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< iterator_of<char_array_t>::type, char* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< iterator_of<char[10]>::type, char* >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< const_iterator_of<char_array_t>::type, const char* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< const_iterator_of<char[10]>::type, const char* >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< difference_type_of<char_array_t>::type,
|
BOOST_STATIC_ASSERT(( is_same< difference_type_of<char_array_t>::type,
|
||||||
::std::ptrdiff_t >::value ));
|
::std::ptrdiff_t >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< size_type_of<char_array_t>::type, std::size_t >::value ));
|
BOOST_STATIC_ASSERT(( is_same< size_type_of<char_array_t>::type, std::size_t >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<char_array_t>::type, char* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<char[10]>::type, char* >::value ));
|
||||||
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<const char_array_t>::type, const char* >::value ));
|
BOOST_STATIC_ASSERT(( is_same< result_iterator_of<const char[10]>::type, const char* >::value ));
|
||||||
|
|
||||||
BOOST_CHECK_EQUAL( begin( char_s ), char_s );
|
BOOST_CHECK_EQUAL( begin( char_s ), char_s );
|
||||||
std::size_t sz = size( char_s );
|
std::size_t sz = size( char_s );
|
||||||
@ -90,8 +90,8 @@ void check_char()
|
|||||||
BOOST_CHECK_EQUAL( sz, std::char_traits<char>::length( char_s ) );
|
BOOST_CHECK_EQUAL( sz, std::char_traits<char>::length( char_s ) );
|
||||||
|
|
||||||
BOOST_CHECK_EQUAL( begin( my_string ), my_string );
|
BOOST_CHECK_EQUAL( begin( my_string ), my_string );
|
||||||
const char* end2 = begin( my_string ) + size( my_string );
|
iterator_of<char[15]>::type end2 = begin( my_string ) + size( my_string );
|
||||||
const char* end3 = end( my_string );
|
iterator_of<char[15]>::type end3 = end( my_string );
|
||||||
BOOST_CHECK_EQUAL( end3, end2 );
|
BOOST_CHECK_EQUAL( end3, end2 );
|
||||||
BOOST_CHECK_EQUAL( empty( my_string ), (my_string == 0 || my_string[0] == char()) );
|
BOOST_CHECK_EQUAL( empty( my_string ), (my_string == 0 || my_string[0] == char()) );
|
||||||
BOOST_CHECK_EQUAL( size( my_string ), my_string_length );
|
BOOST_CHECK_EQUAL( size( my_string ), my_string_length );
|
||||||
|
Reference in New Issue
Block a user