public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "anlauf at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/107576] [10/11/12/13 Regression] ICE in gfc_conv_procedure_call, at fortran/trans-expr.cc:6193
Date: Tue, 15 Nov 2022 21:41:25 +0000	[thread overview]
Message-ID: <bug-107576-4-hAo9liSsEc@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-107576-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107576

--- Comment #9 from anlauf at gcc dot gnu.org ---
Something like the following rejects NULL when there is no interface:

diff --git a/gcc/fortran/interface.cc b/gcc/fortran/interface.cc
index 49dbd1d886c..62b325b726d 100644
--- a/gcc/fortran/interface.cc
+++ b/gcc/fortran/interface.cc
@@ -4160,6 +4180,14 @@ gfc_procedure_use (gfc_symbol *sym, gfc_actual_arglist
**ap, locus *where)
              return false;
            }

+         if (a->expr && a->expr->expr_type == EXPR_NULL)
+           {
+             gfc_error ("Passing intrinsic NULL as actual argument at %L "
+                        "requires an explicit interface", &a->expr->where);
+             a->expr->error = 1;
+             return false;
+           }
+
          /* TS 29113, C407b.  */
          if (a->expr && a->expr->expr_type == EXPR_VARIABLE
              && symbol_rank (a->expr->symtree->n.sym) == -1)

  parent reply	other threads:[~2022-11-15 21:41 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-08 17:27 [Bug fortran/107576] New: " gscfq@t-online.de
2022-11-08 17:28 ` [Bug fortran/107576] " gscfq@t-online.de
2022-11-08 17:36 ` rguenth at gcc dot gnu.org
2022-11-08 20:43 ` anlauf at gcc dot gnu.org
2022-11-11 21:43 ` anlauf at gcc dot gnu.org
2022-11-11 22:00 ` anlauf at gcc dot gnu.org
2022-11-14 17:29 ` gscfq@t-online.de
2022-11-14 18:03 ` anlauf at gcc dot gnu.org
2022-11-14 20:21 ` gscfq@t-online.de
2022-11-14 20:46 ` anlauf at gcc dot gnu.org
2022-11-15 21:41 ` anlauf at gcc dot gnu.org [this message]
2022-11-17 20:49 ` anlauf at gcc dot gnu.org
2022-11-18 18:21 ` cvs-commit at gcc dot gnu.org
2022-11-25 22:19 ` cvs-commit at gcc dot gnu.org
2022-11-25 22:27 ` cvs-commit at gcc dot gnu.org
2022-11-25 22:30 ` cvs-commit at gcc dot gnu.org
2022-11-25 22:31 ` anlauf at gcc dot gnu.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=bug-107576-4-hAo9liSsEc@http.gcc.gnu.org/bugzilla/ \
    --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).