From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1914) id C009139B4400; Fri, 18 Jun 2021 08:38:14 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org C009139B4400 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Pierre-Marie de Rodat To: gcc-cvs@gcc.gnu.org Subject: [gcc r12-1618] [Ada] Remove dead code for overlapping actuals in prefix notation X-Act-Checkin: gcc X-Git-Author: Piotr Trojanek X-Git-Refname: refs/heads/master X-Git-Oldrev: 2a8dbd6b244df31819c378626007c45f001f7136 X-Git-Newrev: 9c2886684f8263f5f63b15f358ce33bfc67d27ce Message-Id: <20210618083814.C009139B4400@sourceware.org> Date: Fri, 18 Jun 2021 08:38:14 +0000 (GMT) X-BeenThere: gcc-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 Jun 2021 08:38:14 -0000 https://gcc.gnu.org/g:9c2886684f8263f5f63b15f358ce33bfc67d27ce commit r12-1618-g9c2886684f8263f5f63b15f358ce33bfc67d27ce Author: Piotr Trojanek Date: Mon Mar 15 14:53:29 2021 +0100 [Ada] Remove dead code for overlapping actuals in prefix notation gcc/ada/ * sem_warn.adb (Warn_On_Overlapping_Actuals): Remove dead branch for overlapping actuals in prefix notation. Diff: --- gcc/ada/sem_warn.adb | 42 ++++++------------------------------------ 1 file changed, 6 insertions(+), 36 deletions(-) diff --git a/gcc/ada/sem_warn.adb b/gcc/ada/sem_warn.adb index e85f4930175..d612d53dbea 100644 --- a/gcc/ada/sem_warn.adb +++ b/gcc/ada/sem_warn.adb @@ -3839,45 +3839,15 @@ package body Sem_Warn is or else Error_To_Warning; - -- If the call was written in prefix notation, and thus - -- its prefix before rewriting was a selected component, - -- count only visible actuals in call. - - if Is_Entity_Name (First_Actual (N)) - and then Nkind (Original_Node (N)) = Nkind (N) - and then Nkind (Name (Original_Node (N))) = - N_Selected_Component - and then - Is_Entity_Name (Prefix (Name (Original_Node (N)))) - and then - Entity (Prefix (Name (Original_Node (N)))) = - Entity (First_Actual (N)) - then - if Act1 = First_Actual (N) then - Error_Msg_FE - ("