public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "burnus at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/42597] ICE with procedure pointer initialized to null() Date: Mon, 04 Jan 2010 09:55:00 -0000 [thread overview] Message-ID: <20100104095526.28482.qmail@sourceware.org> (raw) In-Reply-To: <bug-42597-17129@http.gcc.gnu.org/bugzilla/> ------- Comment #1 from burnus at gcc dot gnu dot org 2010-01-04 09:55 ------- Confirmed. The initialization works - if in a procedure or program, but it fails in the declaration part of a module. The problem seems to be related to returning an array - one should not have called gfc_build_null_descriptor but via get_proc_pointer_decl the routine gfc_conv_initializer (with pointer = true and array = false). Actually, the following looks bogus: DECL_INITIAL (decl) = gfc_conv_initializer (sym->value, &sym->ts, TREE_TYPE (decl), sym->attr.dimension, sym->attr.proc_pointer); Namely, the last but one argument. I think, it should be: sym->attr.proc_pointer ? false : sym->attr.dimension But that does not explain why it seems to work elsewhere. Janus, what do you think? -- burnus at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |janus at gcc dot gnu dot org Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Keywords| |ice-on-valid-code Last reconfirmed|0000-00-00 00:00:00 |2010-01-04 09:55:26 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42597
next prev parent reply other threads:[~2010-01-04 9:55 UTC|newest] Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top 2010-01-03 17:43 [Bug fortran/42597] New: " mrestelli at gmail dot com 2010-01-04 9:55 ` burnus at gcc dot gnu dot org [this message] 2010-01-04 11:33 ` [Bug fortran/42597] " burnus at gcc dot gnu dot org 2010-01-07 8:12 ` burnus at gcc dot gnu dot org 2010-01-07 8:13 ` burnus at gcc dot gnu dot org 2010-02-07 4:03 ` 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=20100104095526.28482.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).