From 6e8e2112ba0e563e748c0e65de63a40ae9e3419d Mon Sep 17 00:00:00 2001 From: Christian Mazakas Date: Fri, 7 Oct 2022 14:51:40 -0700 Subject: [PATCH] Rearrange SFINAE to appease msvc-14.0 in erase() member function template --- include/boost/unordered/detail/foa.hpp | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/include/boost/unordered/detail/foa.hpp b/include/boost/unordered/detail/foa.hpp index 0dbf230f..ea8aabcf 100644 --- a/include/boost/unordered/detail/foa.hpp +++ b/include/boost/unordered/detail/foa.hpp @@ -1097,13 +1097,11 @@ public: --size_; } - template< - typename Key, - typename std::enable_if< - !std::is_convertible::value&& - !std::is_convertible::value>::type* =nullptr - > - std::size_t erase(Key&& x) + template + auto erase(Key&& x) -> typename std::enable_if< + !boost::is_convertible::value&& + !boost::is_convertible::value, std::size_t>::type + erase(Key&& x) { auto it=find(x); if(it!=end()){