From patchwork Fri Jan 27 14:01:46 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tobias Burnus X-Patchwork-Id: 138227 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 82B58B6F9C for ; Sat, 28 Jan 2012 01:02:10 +1100 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1328277731; h=Comment: DomainKey-Signature:Received:Received:Received:Received: Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject: References:In-Reply-To:Content-Type:Mailing-List:Precedence: List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender: Delivered-To; bh=V4yQTlW0W3I3n0rXlZvbId/C4qg=; b=x4NrDpSTwYwD0EF Z4gf+yHDOtxNz04vWePrvhOpS/Fr9BHnOR4/rJ7Ya5ujFdX6mh8Bq2caWevICack +oNVUAXf+tcQ6GLSqiAsWTI/43ettmJ0teKCaaEDZ/DGr/ylzfNGva9VHOAvLpw6 QahG+6PTqmvK4oGUh3+OE5NfU+DI= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=UZMEVdEcSaENGfemN9wC0/qHJ9k63CH8uKGr/AK3uVhB/34Vhwr65TQoy0EY4H Yhbjzoh4LhmzvYyxYBBc5oMxQXeUluF9vtKe4dN4hMhb+yX5ZvnRdNWRE1WM1L4x /TYd5RT1xjK18fefbyQuxQovFD2oYAH4v+vE1nGbkC/5k=; Received: (qmail 32627 invoked by alias); 27 Jan 2012 14:02:04 -0000 Received: (qmail 32614 invoked by uid 22791); 27 Jan 2012 14:02:03 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_NONE X-Spam-Check-By: sourceware.org Received: from mx01.qsc.de (HELO mx01.qsc.de) (213.148.129.14) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 27 Jan 2012 14:01:49 +0000 Received: from [192.168.178.22] (port-92-204-113-100.dynamic.qsc.de [92.204.113.100]) by mx01.qsc.de (Postfix) with ESMTP id D60F83CE84; Fri, 27 Jan 2012 15:01:47 +0100 (CET) Message-ID: <4F22AE4A.3070402@net-b.de> Date: Fri, 27 Jan 2012 15:01:46 +0100 From: Tobias Burnus User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:9.0) Gecko/20111220 Thunderbird/9.0 MIME-Version: 1.0 To: Paul Richard Thomas CC: gcc patches , gfortran Subject: Re: [Patch, Fortran] Fix elemental diagnostic for polymorphic dummies References: <4F21E732.6070109@net-b.de> In-Reply-To: Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org On 01/27/2012 01:24 PM, Paul Richard Thomas wrote: > This is 'obvious' - OK for trunk. Thanks for the review. I realized that the following chunk was not in the submitted patch. I have no idea why it got lost, but after committal of the original patch and update of by devel tree it showed up with "svn diff". That case is already tested for in the previously committed patch. Follow up committed as Rev. 183625. Tobias Index: gcc/fortran/ChangeLog =================================================================== --- gcc/fortran/ChangeLog (revision 183624) +++ gcc/fortran/ChangeLog (working copy) @@ -1,5 +1,12 @@ 2012-01-27 Tobias Burnus + PR fortran/52016 + * resolve.c (resolve_formal_arglist): Fix elemental + constraint checks for polymorphic dummies also for + pointers. + +2012-01-27 Tobias Burnus + PR fortran/51970 PR fortran/51977 * primary.c (gfc_match_varspec. gfc_match_rvalue): Set Index: gcc/fortran/resolve.c =================================================================== --- gcc/fortran/resolve.c (revision 183624) +++ gcc/fortran/resolve.c (working copy) @@ -401,7 +401,9 @@ continue; } - if (sym->attr.pointer) + if (sym->attr.pointer + || (sym->ts.type == BT_CLASS && CLASS_DATA (sym) + && CLASS_DATA (sym)->attr.class_pointer)) { gfc_error ("Argument '%s' of elemental procedure at %L cannot " "have the POINTER attribute", sym->name,