From: Ghjuvan Lacambre Date: Wed, 4 May 2022 11:31:07 +0000 (+0200) Subject: [Ada] Fix "formal parameter & is not referenced" not being properly tagged X-Git-Tag: basepoints/gcc-14~6321 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=fdb2f2e696250fafc13635ac8c026d82e05f7738;p=thirdparty%2Fgcc.git [Ada] Fix "formal parameter & is not referenced" not being properly tagged gcc/ada/ * sem_warn.adb (Warn_On_Unreferenced_Entity): Fix warning tag. --- diff --git a/gcc/ada/sem_warn.adb b/gcc/ada/sem_warn.adb index 3dd8cd049ff..b23be725437 100644 --- a/gcc/ada/sem_warn.adb +++ b/gcc/ada/sem_warn.adb @@ -4414,9 +4414,10 @@ package body Sem_Warn is if (No (S) or else not Is_Dispatching_Operation (S)) and then not Is_Trivial_Subprogram (Scope (E)) + and then Check_Unreferenced_Formals then Error_Msg_NE -- CODEFIX - ("?u?formal parameter & is not referenced!", + ("?f?formal parameter & is not referenced!", E, Spec_E); end if; end;