From 3a722d278d2c864e2705833766edf9c6a261dca0 Mon Sep 17 00:00:00 2001 From: jak1 Date: Fri, 7 Apr 2023 03:07:40 +0200 Subject: fixed gcc deprecation (unary & not1) --- src/utils/dtor.h | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'src/utils') diff --git a/src/utils/dtor.h b/src/utils/dtor.h index 368aa5ed9..2fb8d1908 100644 --- a/src/utils/dtor.h +++ b/src/utils/dtor.h @@ -29,19 +29,18 @@ #include "localconsts.h" template -struct dtor final : public std::unary_function +struct dtor final { A_DEFAULT_COPY(dtor) - void operator()(T &ptr) + constexpr void operator()(T &ptr) { delete ptr; } }; template -struct dtor > : -public std::unary_function , void> +struct dtor > { - void operator()(std::pair &pair) + constexpr void operator()(std::pair &pair) { delete pair.second; } }; -- cgit v1.2.3-70-g09d2