Previous fix broke some tests, second try at warning suppression.

This commit is contained in:
jzmaddock
2018-04-19 09:12:18 +01:00
parent 39f48141c5
commit a97d5f32d4
2 changed files with 4 additions and 3 deletions

View File

@ -25,7 +25,7 @@ namespace boost_has_partial_std_allocator{
//
template <class T>
int test_allocator(const T&)
int test_allocator(const T& i)
{
typedef std::allocator<int> alloc1_t;
#if !((__cplusplus > 201700) || (defined(_MSVC_LANG) && (_MSVC_LANG > 201700)))
@ -38,7 +38,7 @@ int test_allocator(const T&)
typedef typename alloc1_t::value_type value_type BOOST_UNUSED_ATTRIBUTE;
#endif
alloc1_t a1;
(void)i;
#if !((__cplusplus > 201700) || (defined(_MSVC_LANG) && (_MSVC_LANG > 201700)))
pointer p = a1.allocate(1);
const_pointer cp = p;

View File

@ -25,7 +25,7 @@ namespace boost_no_std_allocator{
#endif
template <class T>
int test_allocator(const T&)
int test_allocator(const T& i)
{
typedef std::allocator<int> alloc1_t;
#if !((__cplusplus > 201700) || (defined(_MSVC_LANG) && (_MSVC_LANG > 201700)))
@ -41,6 +41,7 @@ int test_allocator(const T&)
alloc1_t a1;
alloc1_t a2(a1);
(void)i;
#if !((__cplusplus > 201700) || (defined(_MSVC_LANG) && (_MSVC_LANG > 201700)))
// stuff deprecated in C++17:
typedef typename alloc1_t::BOOST_NESTED_TEMPLATE rebind<double> binder_t;