From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.smtpout.orange.fr (smtp09.smtpout.orange.fr [80.12.242.131]) by sourceware.org (Postfix) with ESMTPS id 898FB3857BA6 for ; Thu, 6 Oct 2022 08:37:40 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 898FB3857BA6 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=orange.fr Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=orange.fr Received: from [192.168.1.17] ([86.215.174.255]) by smtp.orange.fr with ESMTPA id gMNooNZP2eT4cgMNtosBsY; Thu, 06 Oct 2022 10:37:37 +0200 X-ME-Helo: [192.168.1.17] X-ME-Auth: bW9yaW4tbWlrYWVsQG9yYW5nZS5mcg== X-ME-Date: Thu, 06 Oct 2022 10:37:37 +0200 X-ME-IP: 86.215.174.255 Message-ID: Date: Thu, 6 Oct 2022 10:37:32 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.3.1 Subject: Re: [PATCH, v2] Fortran: reject procedures and procedure pointers as IO element [PR107074] To: Harald Anlauf Cc: fortran , gcc-patches References: <3ff755f3-d514-f7cc-f79c-c554b60c2b83@orange.fr> Content-Language: en-US From: Mikael Morin In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM,JMQ_SPF_NEUTRAL,KAM_DMARC_STATUS,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Le 05/10/2022 à 22:40, Harald Anlauf a écrit : > Hi Mikael, > >> Gesendet: Mittwoch, 05. Oktober 2022 um 12:34 Uhr >> Von: "Mikael Morin" >> Please move the check to resolve_transfer in resolve.cc. > > I have done this, see attached updated patch. > > Regtests cleanly on x86_64-pc-linux-gnu. > >> Strangely, the patch doesn't seem to fix the problem on the testcase >> here. There is an outer parenthese expression preventing the condition >> you added from triggering. Can you double check? > > You are right: I had a one-liner in my worktree from PR105371 that > fixes an issue with gfc_simplify_merge and that seems to help here. > It is now included. > The rest looks good, but I'm not sure about your one-liner. I will try to come with a real test later, but in principle, if you have a call to FOO(MERGE(A,A,.TRUE.)) you can't simplify it to FOO(A) as writes to the argument in FOO should not overwrite the content of A. The dummy should be associated with a temporary value, not to A.