public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Tobias Burnus <tobias@codesourcery.com>
To: Harald Anlauf <anlauf@gmx.de>
Cc: fortran <fortran@gcc.gnu.org>, gcc-patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] PR fortrsn/101564 - ICE in resolve_allocate_deallocate, at fortran/resolve.c:8169
Date: Wed, 28 Jul 2021 12:23:40 +0200	[thread overview]
Message-ID: <7f67fe55-78b2-ee0f-6cf6-275bf9349740@codesourcery.com> (raw)
In-Reply-To: <trinity-e2b2d292-0335-4ee8-bd66-e07bb4c96299-1627422165026@3c-app-gmx-bs70>

Hi Harald,

On 27.07.21 23:42, Harald Anlauf wrote:
> This almost worked, needing only a restriction to %KIND and %LEN.
> Note that %RE and %IM are usually definable.
Well spotted :-)
> Regtested on x86_64-pc-linux-gnu.  OK?
>> LGTM - except [...] feel free add them and commit without further review.
>> [...]
> I have added the updated "final" version of the patch to give
> everybody another 24h to have a look, and will commit if nobody
> complains.
LGTM - thanks again.

> [...] with fixing a few issues on the way before Gerhard finds them...

:-)

Tobias

> Fortran: ICE in resolve_allocate_deallocate for invalid STAT argument
>
> gcc/fortran/ChangeLog:
>
>       PR fortran/101564
>       * expr.c (gfc_check_vardef_context): Add check for KIND and LEN
>       parameter inquiries.
>       * match.c (gfc_match): Fix comment for %v code.
>       (gfc_match_allocate, gfc_match_deallocate): Replace use of %v code
>       by %e in gfc_match to allow for function references as STAT and
>       ERRMSG arguments.
>       * resolve.c (resolve_allocate_deallocate): Avoid NULL pointer
>       dereferences and shortcut for bad STAT and ERRMSG argument to
>       (DE)ALLOCATE.  Remove bogus parts of checks for STAT and ERRMSG.
>
> gcc/testsuite/ChangeLog:
>
>       PR fortran/101564
>       * gfortran.dg/allocate_stat_3.f90: New test.
>       * gfortran.dg/allocate_stat.f90: Adjust error messages.
>       * gfortran.dg/implicit_11.f90: Likewise.
>       * gfortran.dg/inquiry_type_ref_3.f90: Likewise.
-----------------
Siemens Electronic Design Automation GmbH; Anschrift: Arnulfstraße 201, 80634 München; Gesellschaft mit beschränkter Haftung; Geschäftsführer: Thomas Heurung, Frank Thürauf; Sitz der Gesellschaft: München; Registergericht München, HRB 106955

      reply	other threads:[~2021-07-28 10:23 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-21 20:36 Harald Anlauf
2021-07-22 17:55 ` Tobias Burnus
2021-07-22 19:50   ` Harald Anlauf
2021-07-23  8:17     ` Tobias Burnus
2021-07-26 21:55       ` Harald Anlauf
2021-07-27  7:52         ` Tobias Burnus
2021-07-27 21:42           ` Harald Anlauf
2021-07-28 10:23             ` Tobias Burnus [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=7f67fe55-78b2-ee0f-6cf6-275bf9349740@codesourcery.com \
    --to=tobias@codesourcery.com \
    --cc=anlauf@gmx.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).