forked from boostorg/type_index
Update unit test to remove shared_ptr on compilers less than C++11.
This commit is contained in:
@ -249,12 +249,14 @@ void boost_shared_ptr()
|
||||
|
||||
void std_shared_ptr()
|
||||
{
|
||||
#if defined(__cplusplus) && (__cplusplus >= 201103L)
|
||||
using namespace boost::typeindex;
|
||||
std::shared_ptr<single_derived> d = std::make_shared<single_derived>();
|
||||
std::shared_ptr<base> b = d;
|
||||
std::shared_ptr<single_derived> d2 = runtime_pointer_cast<single_derived>(b);
|
||||
BOOST_TEST_NE(d2, std::shared_ptr<single_derived>());
|
||||
BOOST_TEST_EQ(d2->name, "single_derived");
|
||||
#endif
|
||||
}
|
||||
|
||||
int main() {
|
||||
|
Reference in New Issue
Block a user