From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21985 invoked by alias); 6 Aug 2011 23:14:27 -0000 Received: (qmail 21965 invoked by uid 22791); 6 Aug 2011 23:14:25 -0000 X-SWARE-Spam-Status: No, hits=-1.2 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,RP_MATCHES_RCVD,TW_SV X-Spam-Check-By: sourceware.org Received: from smtp21.services.sfr.fr (HELO smtp21.services.sfr.fr) (93.17.128.3) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 06 Aug 2011 23:14:08 +0000 Received: from filter.sfr.fr (localhost [127.0.0.1]) by msfrf2111.sfr.fr (SMTP Server) with ESMTP id 4529E7000089; Sun, 7 Aug 2011 01:14:07 +0200 (CEST) Received: from gimli.local (146.15.72.86.rev.sfr.net [86.72.15.146]) by msfrf2111.sfr.fr (SMTP Server) with ESMTP id EC7BF7000088; Sun, 7 Aug 2011 01:14:06 +0200 (CEST) X-SFR-UUID: 20110806231406968.EC7BF7000088@msfrf2111.sfr.fr From: Mikael Morin To: fortran@gcc.gnu.org Subject: Re: [Patch, Fortran, OOP] PR 49638: [OOP] length parameter is ignored when overriding type bound character functions with constant length. Date: Sun, 07 Aug 2011 03:39:00 -0000 User-Agent: KMail/1.13.5 (FreeBSD/8.2-PRERELEASE; KDE/4.5.5; amd64; ; ) Cc: Janus Weil , Thomas Koenig , "gcc-patches" References: <4E3DB94B.2050702@netcologne.de> In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201108070114.04935.mikael.morin@sfr.fr> X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2011-08/txt/msg00722.txt.bz2 On Sunday 07 August 2011 00:21:46 Janus Weil wrote: > Well, ok. After this amount of discussion, how about we start with the > easy things: Here is a preparational patch (basically a subset of the > previous one), which does not do any real changes yet, only some > preparation and cleanup: > * It moves check_typebound_override to interface.c and prefixes it > with gfc_ (I don't like moving and modifying it at the same time). > * It add the commutativity of multiplication in gfc_dep_compare_expr. > * It does some minor cleanup in dependency.c (making two routines > static and removing an unused argument). > > Ok for trunk? > > Cheers, > Janus > > > 2011-08-06 Janus Weil > > PR fortran/49638 > * dependency.h (gfc_is_same_range,gfc_are_identical_variables): Remove > two prototypes. > * dependency.c (gfc_are_identical_variables): Made static and renamed. I think both the old and the new name should appear. Usually I use (old, new): Rename the former to the latter > (gfc_dep_compare_expr): Renamed 'gfc_are_identical_variables', handle > commutativity of multiplication. > (gfc_is_same_range): Made static and renamed, removed argument 'def'. Same here. > (check_section_vs_section): Renamed 'gfc_is_same_range'. > * gfortran.h (gfc_check_typebound_override): New prototype. > * interface.c (gfc_check_typebound_override): Moved here from ... > * resolv.c (check_typebound_override): ... here (and renamed). > (resolve_typebound_procedure): Renamed 'check_typebound_override'. Index: gcc/fortran/dependency.h =================================================================== --- gcc/fortran/dependency.h (revision 177528) +++ gcc/fortran/dependency.h (working copy) @@ -37,11 +37,8 @@ gfc_expr *gfc_get_noncopying_intrinsic_argument (g int gfc_check_fncall_dependency (gfc_expr *, sym_intent, gfc_symbol *, gfc_actual_arglist *, gfc_dep_check); int gfc_check_dependency (gfc_expr *, gfc_expr *, bool); -int gfc_is_same_range (gfc_array_ref *, gfc_array_ref *, int, int); +/*int gfc_is_same_range (gfc_array_ref *, gfc_array_ref *, int, bool);*/ int gfc_expr_is_one (gfc_expr *, int); identical_variables (gfc_expr *, gfc_expr *); I would just remove it together with the commented code in trans-array.c. Nobody is likely to use it soon, and it remains available through svn if needed. Otherwise OK. Please give Thomas (or others) some time to comment before commiting. Mikael