public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "janus at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/42335] [OOP] ICE on CLASS IS (bad_identifier) Date: Wed, 09 Dec 2009 18:17:00 -0000 [thread overview] Message-ID: <20091209181730.27661.qmail@sourceware.org> (raw) In-Reply-To: <bug-42335-6318@http.gcc.gnu.org/bugzilla/> ------- Comment #3 from janus at gcc dot gnu dot org 2009-12-09 18:17 ------- Mine. I think this one-liner is all that's needed: Index: gcc/fortran/symbol.c =================================================================== --- gcc/fortran/symbol.c (revision 155023) +++ gcc/fortran/symbol.c (working copy) @@ -2476,7 +2476,7 @@ select_type_insert_tmp (gfc_symtree **st) { gfc_select_type_stack *stack = select_type_stack; for (; stack; stack = stack->prev) - if ((*st)->n.sym == stack->selector) + if ((*st)->n.sym == stack->selector && stack->tmp) *st = stack->tmp; } With this, the test case gives: c0.f90:16.20: class is (bad_id) ! ICE 1 Error: 'bad_id' at (1) is not an accessible derived type c0.f90:17.36: this%elements(:) = v%elements(:) 1 Error: 'elements' at (1) is not a member of the 'vector_class' structure -- janus at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|unassigned at gcc dot gnu |janus at gcc dot gnu dot org |dot org | Status|NEW |ASSIGNED Last reconfirmed|2009-12-09 18:03:21 |2009-12-09 18:17:30 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42335
next prev parent reply other threads:[~2009-12-09 18:17 UTC|newest] Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top 2009-12-08 21:46 [Bug fortran/42335] New: " anlauf at gmx dot de 2009-12-09 18:03 ` [Bug fortran/42335] " janus at gcc dot gnu dot org 2009-12-09 18:06 ` janus at gcc dot gnu dot org 2009-12-09 18:17 ` janus at gcc dot gnu dot org [this message] 2009-12-11 14:41 ` janus at gcc dot gnu dot org 2009-12-11 15:02 ` janus at gcc dot gnu dot org 2009-12-22 17:59 ` hjl dot tools at gmail dot com
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=20091209181730.27661.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: linkBe 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).