public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "pault at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/32689] [4.3 regression] TRANSFER returns scalar, even if MOLD is an array
Date: Mon, 09 Jul 2007 21:33:00 -0000	[thread overview]
Message-ID: <20070709213326.22765.qmail@sourceware.org> (raw)
In-Reply-To: <bug-32689-6318@http.gcc.gnu.org/bugzilla/>



------- Comment #2 from pault at gcc dot gnu dot org  2007-07-09 21:33 -------
(In reply to comment #1)

How wierd and wonderful - whilst it is a regression, it is only just; given the
timing of gfc_array_transfer and gfc_simplify_transfer, the latter undid the
former by only a few months or so:)

Really galling is that Brooks and I missed this case and that the fix is so
very easy *sigh*

Index: gcc/fortran/simplify.c
===================================================================
*** gcc/fortran/simplify.c      (revision 126461)
--- gcc/fortran/simplify.c      (working copy)
*************** gfc_simplify_transfer (gfc_expr *source,
*** 3924,3930 ****

    /* Set the number of elements in the result, and determine its size.  */
    result_elt_size = gfc_target_expr_size (mold_element);
!   if (mold->expr_type == EXPR_ARRAY || size)
      {
        int result_length;

--- 3924,3930 ----

    /* Set the number of elements in the result, and determine its size.  */
    result_elt_size = gfc_target_expr_size (mold_element);
!   if (mold->expr_type == EXPR_ARRAY || mold->rank || size)
      {
        int result_length;

I will commit this tomorrow morning, with two other "obvious" patches, after
regtesting.

Paul


-- 

pault at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |pault at gcc dot gnu dot org
                   |dot org                     |
             Status|NEW                         |ASSIGNED
   Last reconfirmed|2007-07-09 09:10:41         |2007-07-09 21:33:26
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32689


  parent reply	other threads:[~2007-07-09 21:33 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-09  7:52 [Bug fortran/32689] New: [4.3 regression] with SIZE or TRANSFER anlauf at gmx dot de
2007-07-09  9:10 ` [Bug fortran/32689] [4.3 regression] TRANSFER returns scalar, even if MOLD is an array dfranke at gcc dot gnu dot org
2007-07-09 21:33 ` pault at gcc dot gnu dot org [this message]
2007-07-10  5:11 ` pault at gcc dot gnu dot org
2007-07-10  5:12 ` pault at gcc dot gnu dot org

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=20070709213326.22765.qmail@sourceware.org \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@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).