I see new GCC 12 warnings: [ 49s] util.cxx: In function 'void ltrim(std::string&)': [ 49s] util.cxx:1699:56: error: 'std::pointer_to_unary_function<_Arg, _Result> std::ptr_fun(_Result (*)(_Arg)) [with _Arg = int; _Result = int]' is deprecated: use 'std::function' instead [-Werror=deprecated-declarations] [ 49s] 1699 | std::not1(std::ptr_fun<int, int>(std::isspace)))); [ 49s] | ~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~ [ 49s] In file included from /usr/include/c++/12/string:48, [ 49s] from util.h:8, [ 49s] from util.cxx:17: [ 49s] /usr/include/c++/12/bits/stl_function.h:1126:5: note: declared here [ 49s] 1126 | ptr_fun(_Result (*__x)(_Arg)) [ 49s] | ^~~~~~~ [ 49s] util.cxx:1699:33: error: 'constexpr std::unary_negate<_Predicate> std::not1(const _Predicate&) [with _Predicate = pointer_to_unary_function<int, int>]' is deprecated: use 'std::not_fn' instead [-Werror=deprecated-declarations] [ 49s] 1699 | std::not1(std::ptr_fun<int, int>(std::isspace)))); [ 49s] | ~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ [ 49s] /usr/include/c++/12/bits/stl_function.h:1046:5: note: declared here [ 49s] 1046 | not1(const _Predicate& __pred) [ 49s] | ^~~~ [ 49s] util.cxx: In function 'void rtrim(std::string&)': [ 49s] util.cxx:1707:43: error: 'std::pointer_to_unary_function<_Arg, _Result> std::ptr_fun(_Result (*)(_Arg)) [with _Arg = int; _Result = int]' is deprecated: use 'std::function' instead [-Werror=deprecated-declarations] [ 49s] 1707 | std::not1(std::ptr_fun<int, int>(std::isspace))).base(), s.end()); [ 49s] | ~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~ [ 49s] /usr/include/c++/12/bits/stl_function.h:1126:5: note: declared here [ 49s] 1126 | ptr_fun(_Result (*__x)(_Arg)) [ 49s] | ^~~~~~~
The ptr_fun related g++ warnings were corrected recently. commit f199d1982ef8 commit 56c498d95