public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "sgk at troutmask dot apl.washington.edu" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/55827] ICE with multiple fortran modules and character lenght determined by an interfaced pure function
Date: Sat, 29 Dec 2012 16:05:00 -0000 [thread overview]
Message-ID: <bug-55827-4-fSNblPjk7w@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-55827-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55827
--- Comment #5 from Steve Kargl <sgk at troutmask dot apl.washington.edu> 2012-12-29 16:04:45 UTC ---
On Fri, Dec 28, 2012 at 10:02:43PM +0000, kargl at gcc dot gnu.org wrote:
>
> Index: class.c
> ===================================================================
> --- class.c (revision 194745)
> +++ class.c (working copy)
> @@ -162,7 +162,8 @@ gfc_fix_class_refs (gfc_expr *e)
> if ((e->expr_type != EXPR_VARIABLE
> && e->expr_type != EXPR_FUNCTION)
> || (e->expr_type == EXPR_FUNCTION
> - && e->value.function.isym != NULL))
> + && e->value.function.isym != NULL)
> + || e->symtree == NULL)
> return;
>
> ts = &e->symtree->n.sym->ts;
> Index: trans-expr.c
> ===================================================================
> --- trans-expr.c (revision 194745)
> +++ trans-expr.c (working copy)
> @@ -5527,7 +5527,7 @@ gfc_conv_function_expr (gfc_se * se, gfc
>
> /* We distinguish statement functions from general functions to improve
> runtime performance. */
> - if (expr->symtree->n.sym->attr.proc == PROC_ST_FUNCTION)
> + if (expr->symtree && expr->symtree->n.sym->attr.proc == PROC_ST_FUNCTION)
> {
> gfc_conv_statement_function (se, expr);
>
Although I agree with Mikael that gfortran should probably
not have a NULL symtree by the time we reach gfc_conv_function_expr,
the above patch regression tests cleanly.
next prev parent reply other threads:[~2012-12-29 16:05 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-28 21:08 [Bug fortran/55827] New: " bugs at stellardeath dot org
2012-12-28 21:12 ` [Bug fortran/55827] " bugs at stellardeath dot org
2012-12-28 22:03 ` kargl at gcc dot gnu.org
2012-12-28 22:41 ` mikael at gcc dot gnu.org
2012-12-29 0:26 ` sgk at troutmask dot apl.washington.edu
2012-12-29 16:05 ` sgk at troutmask dot apl.washington.edu [this message]
2012-12-29 16:40 ` mikael at gcc dot gnu.org
2013-01-01 19:14 ` mikael at gcc dot gnu.org
2013-01-05 13:26 ` mikael at gcc dot gnu.org
2013-01-07 17:57 ` mikael at gcc dot gnu.org
2013-01-07 18:11 ` mikael at gcc dot gnu.org
2013-01-07 18:17 ` mikael at gcc dot gnu.org
2013-01-07 18:19 ` mikael at gcc dot gnu.org
2013-01-07 22:04 ` mikael 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-55827-4-fSNblPjk7w@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).