forked from boostorg/type_traits
Remove stray ; in test file.
Add some rvalue ref tests for is_convertible. Enable use of intrinsics for Intel on Win32. Fix rvalue ref usage in is_convertible. [SVN r79983]
This commit is contained in:
@@ -102,6 +102,8 @@ BOOST_CHECK_INTEGRAL_CONSTANT((::tt::is_convertible<const int*, int[3]>::value),
|
||||
BOOST_CHECK_INTEGRAL_CONSTANT((::tt::is_convertible<const int&, int>::value), true);
|
||||
#ifndef BOOST_NO_RVALUE_REFERENCES
|
||||
BOOST_CHECK_INTEGRAL_CONSTANT((::tt::is_convertible<const int&&, int>::value), true);
|
||||
BOOST_CHECK_INTEGRAL_CONSTANT((::tt::is_convertible<int&&, const int&>::value), true);
|
||||
BOOST_CHECK_INTEGRAL_CONSTANT((::tt::is_convertible<int, int&>::value), false);
|
||||
#endif
|
||||
BOOST_CHECK_INTEGRAL_CONSTANT((::tt::is_convertible<int(&)[4], const int*>::value), true);
|
||||
BOOST_CHECK_INTEGRAL_CONSTANT((::tt::is_convertible<int(&)(int), int(*)(int)>::value), true);
|
||||
|
||||
+1
-1
@@ -260,7 +260,7 @@ struct nothrow_copy_UDT
|
||||
{
|
||||
nothrow_copy_UDT();
|
||||
nothrow_copy_UDT(const nothrow_copy_UDT&)throw();
|
||||
~nothrow_copy_UDT(){};
|
||||
~nothrow_copy_UDT(){}
|
||||
nothrow_copy_UDT& operator=(const nothrow_copy_UDT&);
|
||||
bool operator==(const nothrow_copy_UDT&)const
|
||||
{ return true; }
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#ifdef TEST_STD
|
||||
# include <type_traits>
|
||||
#else
|
||||
# include <boost/type_traits/is_convertible.hpp>
|
||||
# include <boost/type_traits/is_lvalue_reference.hpp>
|
||||
# include <boost/type_traits/is_rvalue_reference.hpp>
|
||||
# include <boost/type_traits/is_reference.hpp>
|
||||
@@ -20,6 +21,7 @@ TT_TEST_BEGIN(rvalue_reference_test)
|
||||
BOOST_CHECK_INTEGRAL_CONSTANT(::tt::is_reference<int (&&)(int)>::value, true);
|
||||
BOOST_CHECK_INTEGRAL_CONSTANT(::tt::is_rvalue_reference<int (&)(int)>::value, false);
|
||||
BOOST_CHECK_INTEGRAL_CONSTANT(::tt::is_rvalue_reference<int (&&)(int)>::value, true);
|
||||
BOOST_CHECK_INTEGRAL_CONSTANT((::tt::is_convertible<int&&, int&>::value), false);
|
||||
#endif
|
||||
|
||||
TT_TEST_END
|
||||
|
||||
Reference in New Issue
Block a user