forked from boostorg/unordered
Unordered: Fix some portability issues in tests.
- Simplify mechanism for detecting traits of test allocators. There were some portability issues, but rather than fix them I've just gone for a simpler mechanism. Does mean that the relevant tests can't be run for other allocators. - Fix a couple of unnecessary_copy_tests, whose results were the wrong way round. - It appears that Visual C++ only implements RVO for implicitly defined copy constructors in debug mode, so adjust a move_test to account for the extra copies now that the copy constructors are explicitly defined. [SVN r73798]
This commit is contained in:
@@ -181,9 +181,9 @@ namespace test
|
||||
}
|
||||
}
|
||||
|
||||
template <bool Value>
|
||||
template <int Value>
|
||||
struct bool_type {
|
||||
enum { value = Value };
|
||||
enum { value = (Value ? true : false) };
|
||||
};
|
||||
|
||||
struct true_type {
|
||||
@@ -194,15 +194,6 @@ namespace test
|
||||
enum { value = false };
|
||||
};
|
||||
|
||||
template <typename Alloc>
|
||||
struct is_select_on_copy : false_type {};
|
||||
template <typename Alloc>
|
||||
struct is_propagate_on_swap : false_type {};
|
||||
template <typename Alloc>
|
||||
struct is_propagate_on_assign : false_type {};
|
||||
template <typename Alloc>
|
||||
struct is_propagate_on_move : false_type {};
|
||||
|
||||
template <typename Alloc>
|
||||
int selected_count(Alloc const&)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user