2017-05-18 Jonathan Wakely <jwakely@redhat.com>
+ PR libstdc++/80478
+ * include/std/functional (_Mem_fn_traits_base): Add specializations
+ for noexcept member function types.
+ * testsuite/20_util/function_objects/mem_fn/80478.cc: New test.
+
+2017-05-18 Jonathan Wakely <jwakely@redhat.com>
+
* doc/xml/manual/policy_data_structures.xml: Fix typo.
* doc/xml/manual/test_policy_data_structures.xml: Likewise.
* doc/html/*: Regenerate.
_GLIBCXX_MEM_FN_TRAITS(&, true_type, false_type)
_GLIBCXX_MEM_FN_TRAITS(&&, false_type, true_type)
+#if __cplusplus > 201402L
+_GLIBCXX_MEM_FN_TRAITS(noexcept, true_type, true_type)
+_GLIBCXX_MEM_FN_TRAITS(& noexcept, true_type, false_type)
+_GLIBCXX_MEM_FN_TRAITS(&& noexcept, false_type, true_type)
+#endif
+
#undef _GLIBCXX_MEM_FN_TRAITS
#undef _GLIBCXX_MEM_FN_TRAITS2
--- /dev/null
+// Copyright (C) 2017 Free Software Foundation, Inc.
+//
+// This file is part of the GNU ISO C++ Library. This library is free
+// software; you can redistribute it and/or modify it under the
+// terms of the GNU General Public License as published by the
+// Free Software Foundation; either version 3, or (at your option)
+// any later version.
+
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+
+// You should have received a copy of the GNU General Public License along
+// with this library; see the file COPYING3. If not see
+// <http://www.gnu.org/licenses/>.
+
+// { dg-options "-std=gnu++17" }
+// { dg-do compile { target c++1z } }
+
+#include <functional>
+
+struct X {
+ void f() noexcept { }
+};
+
+auto f = std::mem_fn(&X::f);