Update unit test to remove shared_ptr on compilers less than C++11.

This commit is contained in:
Chris Glover
2016-09-29 22:29:10 -04:00
parent 1a918009fd
commit b61a7423b7

View File

@ -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() {