public inbox for fortran@gcc.gnu.org
 help / color / mirror / Atom feed
From: Harald Anlauf <anlauf@gmx.de>
To: Paul Richard Thomas <paul.richard.thomas@gmail.com>,
	"fortran@gcc.gnu.org" <fortran@gcc.gnu.org>,
	gcc-patches <gcc-patches@gcc.gnu.org>
Subject: Re: [Patch, fortran] PR104272 - finalizer gets called during allocate
Date: Wed, 5 Apr 2023 20:53:48 +0200	[thread overview]
Message-ID: <2f926853-bf23-cdc3-6bf5-b75b7f7e872e@gmx.de> (raw)
In-Reply-To: <072f908e-ab68-1087-7e86-f7a494d8f35b@gmx.de>

On 4/5/23 20:50, Harald Anlauf via Gcc-patches wrote:
> can you have a look again at the logic in the hunk touching
> trans-stmt.cc (gfc_trans_allocate)?  I haven't checked in detail,
> but it seems possible that you get a stale tmp in the
> gfc_prepend_expr_to_block if (code->ext.alloc.expr3_not_explicit == 0).

Oops, I meant if (code->ext.alloc.expr3_not_explicit != 0)

> Wouldn't it make more sense to move this condition before the braces
> as part of the overall condition?
>
>> OK for mainline?
>
> Otherwise this LGTM.
>
> Thanks for the patch!
>
> Harald



WARNING: multiple messages have this Message-ID
From: Harald Anlauf <anlauf@gmx.de>
To: fortran@gcc.gnu.org
Cc: gcc-patches@gcc.gnu.org
Subject: Re: [Patch, fortran] PR104272 - finalizer gets called during allocate
Date: Wed, 5 Apr 2023 20:53:48 +0200	[thread overview]
Message-ID: <2f926853-bf23-cdc3-6bf5-b75b7f7e872e@gmx.de> (raw)
Message-ID: <20230405185348.zxQU_T4aWCQ7xOw0UnvM1KyCH20SrqAxM7-fjb2Z8l8@z> (raw)
In-Reply-To: <072f908e-ab68-1087-7e86-f7a494d8f35b@gmx.de>

On 4/5/23 20:50, Harald Anlauf via Gcc-patches wrote:
> can you have a look again at the logic in the hunk touching
> trans-stmt.cc (gfc_trans_allocate)?  I haven't checked in detail,
> but it seems possible that you get a stale tmp in the
> gfc_prepend_expr_to_block if (code->ext.alloc.expr3_not_explicit == 0).

Oops, I meant if (code->ext.alloc.expr3_not_explicit != 0)

> Wouldn't it make more sense to move this condition before the braces
> as part of the overall condition?
> 
>> OK for mainline?
> 
> Otherwise this LGTM.
> 
> Thanks for the patch!
> 
> Harald




  reply	other threads:[~2023-04-05 18:53 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-05  6:53 Paul Richard Thomas
2023-04-05 18:50 ` Harald Anlauf
2023-04-05 18:53   ` Harald Anlauf [this message]
2023-04-05 18:53     ` Harald Anlauf
2023-04-05 20:33   ` Paul Richard Thomas

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=2f926853-bf23-cdc3-6bf5-b75b7f7e872e@gmx.de \
    --to=anlauf@gmx.de \
    --cc=fortran@gcc.gnu.org \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=paul.richard.thomas@gmail.com \
    /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).