From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from cc-smtpout1.netcologne.de (cc-smtpout1.netcologne.de [IPv6:2001:4dd0:100:1062:25:2:0:1]) by sourceware.org (Postfix) with ESMTPS id 2401A3858403; Sat, 25 Sep 2021 15:03:21 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 2401A3858403 Received: from cc-smtpin3.netcologne.de (cc-smtpin3.netcologne.de [89.1.8.203]) by cc-smtpout1.netcologne.de (Postfix) with ESMTP id DA30A12602; Sat, 25 Sep 2021 17:03:18 +0200 (CEST) Received: from [IPv6:2001:4dd7:2b84:0:7285:c2ff:fe6c:992d] (2001-4dd7-2b84-0-7285-c2ff-fe6c-992d.ipv6dyn.netcologne.de [IPv6:2001:4dd7:2b84:0:7285:c2ff:fe6c:992d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by cc-smtpin3.netcologne.de (Postfix) with ESMTPSA id 5E19211DEF; Sat, 25 Sep 2021 17:03:14 +0200 (CEST) Subject: Re: [Patch] Fortran: Fix associated intrinsic with assumed rank [PR101334] [was: [PATCH, Fortran] Fixes for F2018 C838 (PR fortran/101334)] To: Tobias Burnus , Sandra Loosemore , "gcc-patches@gcc.gnu.org" , "fortran@gcc.gnu.org" References: From: Thomas Koenig Message-ID: <33dd24aa-6d13-0148-594e-e0a9cb01f3bf@netcologne.de> Date: Sat, 25 Sep 2021 17:03:14 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-NetCologne-Spam: L X-Rspamd-Queue-Id: 5E19211DEF X-Spam-Status: No, score=-3.6 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, NICE_REPLY_A, RCVD_IN_DNSWL_LOW, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Sep 2021 15:03:22 -0000 On 23.09.21 21:13, Tobias Burnus wrote: > On 20.09.21 09:58, Tobias Burnus wrote: > >> On 20.09.21 06:01, Sandra Loosemore wrote: >>> This patch fixes some bugs in handling of assumed-rank arguments >>> revealed by the TS29113 testsuite, ... giving a bogus error when >>> passing one as the first argument to the ASSOCIATED intrinsic.  ... >> >> ...  if I try the following testcase, which is now permitted, I get >> two ICEs. Can you check? >> >> * The first one seems to be a bug in gfc_conv_intrinsic_function, which >>   assumes also for assumed rank that if the first argument is an array, >>   the second argument must also be an array. >> >> * For the second one, I see in the dump: >>     p->dim[p->dtype.rank + -1].stride >>   is seems as '-1' is gfc_array_index_type while 'dtype.rank' is >> signed_char_type_node. > > I fixed that issue + extended the testcase. > > OK for mainline? Hi Tobias, looks good to me. Thanks for the patch! Best regards Thomas