From 2226a7238d310198060ec3f6fea23793480f155b Mon Sep 17 00:00:00 2001 From: joaquintides Date: Tue, 11 Apr 2023 16:32:47 +0200 Subject: [PATCH] adjusted arg constness in erase and erase_if --- include/boost/unordered/detail/foa/concurrent_table.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/boost/unordered/detail/foa/concurrent_table.hpp b/include/boost/unordered/detail/foa/concurrent_table.hpp index 4517ae5c..d51f5279 100644 --- a/include/boost/unordered/detail/foa/concurrent_table.hpp +++ b/include/boost/unordered/detail/foa/concurrent_table.hpp @@ -537,13 +537,13 @@ public: } template - BOOST_FORCEINLINE std::size_t erase(Key&& x) + BOOST_FORCEINLINE std::size_t erase(const Key& x) { - return erase_if(std::forward(x),[](const value_type&){return true;}); + return erase_if(x,[](const value_type&){return true;}); } template - BOOST_FORCEINLINE auto erase_if(Key&& x,F&& f)->typename std::enable_if< + BOOST_FORCEINLINE auto erase_if(const Key& x,F&& f)->typename std::enable_if< !is_execution_policy::value,std::size_t>::type { auto lck=shared_access();