From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3002 invoked by alias); 21 Feb 2011 08:26:14 -0000 Received: (qmail 2968 invoked by uid 22791); 21 Feb 2011 08:26:13 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 21 Feb 2011 08:26:09 +0000 From: "paul.richard.thomas at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/46244] gfc_compare_derived_types is buggy X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Keywords: ice-on-valid-code, patch X-Bugzilla-Severity: normal X-Bugzilla-Who: paul.richard.thomas at gmail dot com X-Bugzilla-Status: ASSIGNED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Date: Mon, 21 Feb 2011 09:37:00 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2011-02/txt/msg02413.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46244 --- Comment #16 from paul.richard.thomas at gmail dot com 2011-02-21 08:25:51 UTC --- Dear Mikael, ....snip.... > Actually none of the gfc_compare_type/gfc_TK_compatible changes are absolutely > necessary to fix this bug. It is just I found it odd that gfc_compare_type was > calling gfc_type_compatible (compatible types are not necessary > equal/equivalent), so I changed it so that gfc_type_compatible calls > gfc_compare_type instead. And then the new gfc_TK_compatible function to not > upset the testsuite. > > Maybe I just don't understand what "compare types" means. :-( ....snip.... > Hem, yes, who wrote this? ( I hope it's not me ;-) ). There have been a number of contributors over the years. Therein lies the problem. Quick fix has been piled on quick fix and the result is something of a mess. "It is just I found it odd that gfc_compare_type was calling gfc_type_compatible (compatible types are not necessary equal/equivalent), so I changed it so that gfc_type_compatible calls gfc_compare_type instead." That was indeed very peculiar. I know who the culprit was but I am not telling :-) If you have time to put this right I, for one, would be very pleased. A Paul