https://gcc.gnu.org/bugzilla/show_bug.cgi?id=128508
--- Comment #5 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Jakub Jelinek <[email protected]>: https://gcc.gnu.org/g:000807c8cac183782fa87ac96fe06fcc68cbd502 commit r17-6366-g000807c8cac183782fa87ac96fe06fcc68cbd502 Author: Jakub Jelinek <[email protected]> Date: Tue Nov 17 22:41:58 2026 +0100 c++: Handle array types next to pointer types in build_invoke [PR128508] With -D_GLIBCXX_DO_NOT_USE_BUILTIN_TRAITS \ -D'__is_invocable(x,y...)=std::is_invocable_v<x,y>' -include type_traits the following test passes, but otherwise (when using the intrinsic __is_invocable trait) it fails. The difference is due to array-to-pointer decay. The following patch treats arrays the same as pointers. 2026-11-17 Jakub Jelinek <[email protected]> PR c++/128508 * method.cc (build_invoke): Handle ARRAY_TYPE like POINTER_TYPE due to array to pointer decay. * g++.dg/ext/is_invocable8.C: New test. Reviewed-by: Jason Merrill <[email protected]>
