Fix has_trivial_destructor_after_move

Most template type parameters 'Allocator' were modified their default type to void since 1.70.0.
These modifications cause has_trivial_destructor_after_move to compile error or yield wrong result.
So, fix them by changing specializations of has_trivial_destructor_after_move.
This commit is contained in:
Mitsuru Kariya
2019-06-01 22:36:54 +09:00
parent 9e2913d4e3
commit f25c767a2b
25 changed files with 555 additions and 58 deletions
+20
View File
@@ -212,5 +212,25 @@ int main()
}
}
////////////////////////////////////
// has_trivial_destructor_after_move testing
////////////////////////////////////
// default allocator
{
typedef boost::container::small_vector<int, 0> cont;
if (boost::has_trivial_destructor_after_move<cont>::value) {
std::cerr << "has_trivial_destructor_after_move(default allocator) test failed" << std::endl;
return 1;
}
}
// std::allocator
{
typedef boost::container::small_vector<int, 0, std::allocator<int> > cont;
if (boost::has_trivial_destructor_after_move<cont>::value) {
std::cerr << "has_trivial_destructor_after_move(std::allocator) test failed" << std::endl;
return 1;
}
}
return 0;
}