forked from boostorg/function
Don't test allocators if they aren't supported
[SVN r14695]
This commit is contained in:
@ -669,6 +669,7 @@ static void do_nothing() {}
|
|||||||
|
|
||||||
static void test_allocator()
|
static void test_allocator()
|
||||||
{
|
{
|
||||||
|
#ifndef BOOST_NO_STD_ALLOCATOR
|
||||||
boost::function<int (int, int), counting_allocator<int> > f;
|
boost::function<int (int, int), counting_allocator<int> > f;
|
||||||
f = plus<int>();
|
f = plus<int>();
|
||||||
f.clear();
|
f.clear();
|
||||||
@ -692,6 +693,7 @@ static void test_allocator()
|
|||||||
dealloc_count = 0;
|
dealloc_count = 0;
|
||||||
fv = &do_nothing;
|
fv = &do_nothing;
|
||||||
fv.clear();
|
fv.clear();
|
||||||
|
#endif // ndef BOOST_NO_STD_ALLOCATOR
|
||||||
}
|
}
|
||||||
|
|
||||||
int test_main(int, char* [])
|
int test_main(int, char* [])
|
||||||
|
Reference in New Issue
Block a user