https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105848
--- Comment #11 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-16 branch has been updated by Patrick Palka <[email protected]>: https://gcc.gnu.org/g:9fad76fa86f5a1464fbe52f926750a389727910d commit r16-9409-g9fad76fa86f5a1464fbe52f926750a389727910d Author: Patrick Palka <[email protected]> Date: Sat Jul 25 16:12:19 2026 -0400 c++: function NTTP argument in pack considered unused [PR126280] This is just the pack version of PR c++/105848, in which our non-dependent call pruning may cause us to not mark an otherwise unused function pointer template argument within a pack as used. PR c++/126280 gcc/cp/ChangeLog: * pt.cc (mark_template_arguments_used): Split out loop into ... (mark_template_arguments_used_1): ... here. Recurse into argument packs. gcc/testsuite/ChangeLog: * g++.dg/template/fn-ptr6.C: New test. Reviewed-by: Jason Merrill <[email protected]> (cherry picked from commit d47f48643b3db4e207b0cc3382f614aa76c9c2c5)
