Skip to content

Commit

Permalink
Most members of std::allocate are deprecated in C++17
Browse files Browse the repository at this point in the history
Replace them by their cousins from std::allocator_traits.

Signed-off-by: Daniela Engert <dani@ngrt.de>
  • Loading branch information
DanielaE committed Mar 30, 2018
1 parent d839580 commit d5f3a54
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions include/boost/gil/image.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,11 @@ namespace boost { namespace gil {
template< typename Pixel, bool IsPlanar = false, typename Alloc=std::allocator<unsigned char> >
class image {
public:
#if defined(BOOST_NO_CXX11_ALLOCATOR)
typedef typename Alloc::template rebind<unsigned char>::other allocator_type;
#else
typedef typename std::allocator_traits<Alloc>::template rebind_alloc<unsigned char> allocator_type;
#endif
typedef typename view_type_from_pixel<Pixel, IsPlanar>::type view_t;
typedef typename view_t::const_t const_view_t;
typedef typename view_t::point_t point_t;
Expand Down

0 comments on commit d5f3a54

Please sign in to comment.