From db072f75e5ade3b9f1f2ff76fcdfda0d3bf028d1 Mon Sep 17 00:00:00 2001 From: Jonathan Wakely Date: Thu, 12 Feb 2026 18:52:12 +0000 Subject: [PATCH] libstdc++: Fix fallback definitions of std::is_member_*_pointer When the builtins aren't used we need a declaration of std::is_function for the fallback definitions of std::is_member_function_pointer and std::is_member_object_pointer. libstdc++-v3/ChangeLog: * include/std/type_traits (is_function): Declare before first use. --- libstdc++-v3/include/std/type_traits | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/libstdc++-v3/include/std/type_traits b/libstdc++-v3/include/std/type_traits index d533dc0ef09..ea700d1ed97 100644 --- a/libstdc++-v3/include/std/type_traits +++ b/libstdc++-v3/include/std/type_traits @@ -674,6 +674,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION : public __bool_constant<__is_member_object_pointer(_Tp)> { }; #else + template + struct is_function; + template struct __is_member_object_pointer_helper : public false_type { }; @@ -696,6 +699,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION : public __bool_constant<__is_member_function_pointer(_Tp)> { }; #else + template + struct is_function; + template struct __is_member_function_pointer_helper : public false_type { }; -- 2.47.3