Index: test/std/utilities/allocator.adaptor/types.pass.cpp =================================================================== --- test/std/utilities/allocator.adaptor/types.pass.cpp +++ test/std/utilities/allocator.adaptor/types.pass.cpp @@ -27,6 +27,7 @@ #include #include +#include #include "allocators.h" @@ -76,11 +77,11 @@ static_assert((std::is_same< std::scoped_allocator_adaptor, A1>::size_type, - unsigned>::value), ""); + std::size_t>::value), ""); static_assert((std::is_same< std::scoped_allocator_adaptor, A1>::difference_type, - int>::value), ""); + std::ptrdiff_t>::value), ""); static_assert((std::is_same< std::scoped_allocator_adaptor, A1>::pointer, Index: test/support/allocators.h =================================================================== --- test/support/allocators.h +++ test/support/allocators.h @@ -12,6 +12,7 @@ #include #include +#include #include "test_macros.h" @@ -85,8 +86,8 @@ typedef T value_type; - typedef unsigned size_type; - typedef int difference_type; + typedef std::size_t size_type; + typedef std::ptrdiff_t difference_type; typedef std::true_type propagate_on_container_move_assignment; Index: test/support/test_allocator.h =================================================================== --- test/support/test_allocator.h +++ test/support/test_allocator.h @@ -51,8 +51,8 @@ template friend class test_allocator; public: - typedef unsigned size_type; - typedef int difference_type; + typedef std::size_t size_type; + typedef std::ptrdiff_t difference_type; typedef T value_type; typedef value_type* pointer; typedef const value_type* const_pointer; @@ -112,8 +112,8 @@ template friend class non_default_test_allocator; public: - typedef unsigned size_type; - typedef int difference_type; + typedef std::size_t size_type; + typedef std::ptrdiff_t difference_type; typedef T value_type; typedef value_type* pointer; typedef const value_type* const_pointer; @@ -173,8 +173,8 @@ template friend class test_allocator; public: - typedef unsigned size_type; - typedef int difference_type; + typedef std::size_t size_type; + typedef std::ptrdiff_t difference_type; typedef void value_type; typedef value_type* pointer; typedef const value_type* const_pointer;