From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from esa3.mentor.iphmx.com (esa3.mentor.iphmx.com [68.232.137.180]) by sourceware.org (Postfix) with ESMTPS id C12D2385E020; Wed, 25 Nov 2020 11:58:35 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org C12D2385E020 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=Tobias_Burnus@mentor.com IronPort-SDR: 16oGNg06rTbs4VJJTJjCRiOSvOfmUC+pnZMQtVaD+tAvofBtpJb4zQVKAIjOCr7CORpTzNT+is tIti9+t4ucHpR20OHNRFO5rkmurXnAgJBnWpVSHknUrhIjoogFZmyBIJpAfYx/SvKy3/blJhqz oBXV08hexF9V/vru1ifXoXUb3ylZpU1VNI0iHLXbK2TeNc7VgeollKLbMhoVWN0ELWENsljJfL 3N3Gx81SJnpMgx7b8x0++CtN2X4jbMfIOz2xMWmgh2iUL5f8DP7vP4HCtobJfDfZiPQ7AciqD3 UhQ= X-IronPort-AV: E=Sophos;i="5.78,368,1599552000"; d="scan'208";a="55460864" Received: from orw-gwy-01-in.mentorg.com ([192.94.38.165]) by esa3.mentor.iphmx.com with ESMTP; 25 Nov 2020 03:58:35 -0800 IronPort-SDR: SzHojon9hpJWj9JYXrDJHnMPtpu4a3c/SODgLO1hn2mvFCzrd+41GwlQ0KnGsI84M3cZEiOV/b cMXWd45En6Shn2XUwzx1QqIJ+hYhwE5gE0HKEDXDlmP+JULC3xHydMv/OLKwKeuEd4lwAsiAZW u7VHkfQaozPlGEnDOl61WHw/+LPTda0fRvRfNClZUrIv4RCDAliUXVxlSTqjkJmQ1U5zClQMC/ AMi2I6SJ3o/OSM2IjAFxbPQOVYlc9kuXQw6W1d35xP4RGqbwg2RW4SNBowW9wUg0uY39m+nejv Cik= Subject: Re: [patch, fortran] Correct fndecls for some library functions To: Thomas Koenig , "fortran@gcc.gnu.org" CC: gcc-patches References: <7d637428-5aab-f3f6-e698-ecaf93084c96@netcologne.de> From: Tobias Burnus Message-ID: <35c31819-2a40-91a3-c917-8d4fb8f52ecc@codesourcery.com> Date: Wed, 25 Nov 2020 12:58:29 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.5.0 MIME-Version: 1.0 In-Reply-To: <7d637428-5aab-f3f6-e698-ecaf93084c96@netcologne.de> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: quoted-printable Content-Language: en-US X-Originating-IP: [137.202.0.90] X-ClientProxiedBy: SVR-IES-MBX-07.mgc.mentorg.com (139.181.222.7) To svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) X-Spam-Status: No, score=-6.3 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS, KAM_DMARC_STATUS, NICE_REPLY_A, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=no autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: fortran@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Fortran mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Nov 2020 11:58:37 -0000 Hello Thomas, On 15.11.20 18:52, Thomas Koenig via Fortran wrote: > > this patch makes sure that we pass the correct fn decls for > some of our library functions. cshift and others still remain > to be implemented. Thanks > +#define ADD_CHAR(c) do { *fp++ =3D c; *fp++ =3D ' '; } while(0) > ... > + ADD_CHAR ('.'); /* Function return. */ Shouldn't this be ".c" instead of ". " as neither global memory is read nor written to? > + if (expr->rank =3D=3D 0) > + { > + if (expr->ts.type =3D=3D BT_CHARACTER) > + { > + ADD_CHAR ('w'); /* Address of character. */ > + ADD_CHAR ('.'); /* Length of character. */ > + } > + } > + else > + ADD_CHAR ('w'); /* Return value is a descriptor. */ shouldn't this be "o"? Otherwise, it looks good to me. Tobias ----------------- Mentor Graphics (Deutschland) GmbH, Arnulfstra=C3=9Fe 201, 80634 M=C3=BCnch= en / Germany Registergericht M=C3=BCnchen HRB 106955, Gesch=C3=A4ftsf=C3=BChrer: Thomas = Heurung, Alexander Walter