https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126448
--- Comment #2 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Eric Botcazou <[email protected]>: https://gcc.gnu.org/g:b97996e63ad956b1feed32d57194dcfa8526f516 commit r17-4968-gb97996e63ad956b1feed32d57194dcfa8526f516 Author: Eric Botcazou <[email protected]> Date: Wed Oct 7 21:34:28 2026 +0200 Ada: Fix bogus warning on use clause for package This occurs when an overloaded subprogram of the package is locally renamed, because this renaming is not recorded as a reference to the package. gcc/ada/ PR ada/126448 * sem_ch8.adb (Analyze_Subprogram_Renaming): Pass Nam instead of Name (N) in the calls to Find_Renamed_Entity. Remove if_statement whose condition is always false. (Find_Renamed_Entity): In the overloaded case and if the overload resolution has succeeded, call Mark_Use_Clauses on the entity. gcc/testsuite/ * gnat.dg/renaming20.adb: New test.
