public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jerry DeLisle <jvdelisle@verizon.net>
To: Tobias Burnus <burnus@net-b.de>
Cc: gcc-patches <gcc-patches@gcc.gnu.org>,
	 "'fortran@gcc.gnu.org'" <fortran@gcc.gnu.org>
Subject: Re: [Patch, Fortran] PR32985 - COMMON checking
Date: Sun, 26 Aug 2007 18:03:00 -0000	[thread overview]
Message-ID: <46D1B494.8030201@verizon.net> (raw)
In-Reply-To: <46C9E5FA.10207@net-b.de>

Tobias Burnus wrote:
> :ADDPATCH fortran:
> 
> This patch does two things:
> 
> a) It fixes a really stupid bug be me. A tree is a tree is a tree -- and
> not a linked list; as I was treating the common_root symtree as list,
> the diagnostic did not always work.
> 
> b) The checking in MATCH comes too early thus the check whether an
> element in COMMON lacks the SEQUENCE type did not work if "TYPE(...)"
> came after "COMMON". Additionally, there was no check for allocateable
> components. BIND(C) is now treated as SEQUENCE with regards to COMMON.
> 
> 
> For COMMON:
> 
> "C589 (R558) If a common-block-object is of a derived type, it shall be a
> sequence type (4.5.1) or a type with the BIND attribute and it shall have no
> default initialization."
> 
> "C588 (R558) A common-block-object shall not be a dummy argument, an
> allocatable variable, a derived-type object with an ultimate component that is
> allocatable, an automatic object, a function name, an entry name, a variable
> with the BIND attribute, or a result name."
> 
> 
> With regards to the standard, this patch fixes the BIND(C) (was
> rejected) and "derived-type object with an ultimate component that is
> allocatable" (was accepted).
> 
> What currently is missing is a check for "it shall have no default
> initialization."
> 
> 
> By the way,  BIND(C) in EQUIVALENCE is not allowed: "C576 An
> equivalence-object shall not be a designator with a base object that is
> [...] a variable with the BIND attribute". (gfortran did and still does
> the right thing.)
> 
> 
> Regression tested on x86-64-linux.
> 
> Ok for the trunk?
> 
This is OK,

Jerry

      reply	other threads:[~2007-08-26 17:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-20 19:20 Tobias Burnus
2007-08-26 18:03 ` Jerry DeLisle [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=46D1B494.8030201@verizon.net \
    --to=jvdelisle@verizon.net \
    --cc=burnus@net-b.de \
    --cc=fortran@gcc.gnu.org \
    --cc=gcc-patches@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).