public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "fxcoudert at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/31591] UBOUND as initialization expression (lacking simplification) Date: Tue, 17 Apr 2007 22:22:00 -0000 [thread overview] Message-ID: <20070417222249.16049.qmail@sourceware.org> (raw) In-Reply-To: <bug-31591-14410@http.gcc.gnu.org/bugzilla/> ------- Comment #8 from fxcoudert at gcc dot gnu dot org 2007-04-17 23:22 ------- (In reply to comment #6) > So, are you saying that LBOUND and UBOUND without the dimension > specifiers do not work at all? I'm saying that gfortran is missing the piece of code that allows is to use UBOUND and LBOUND, without the DIM argument, as specification expression (ie as value assigned to a PARAMETER). So: integer, parameter, dimension(5) :: & TCg_bband_coef_ranks = ubound(TCg_coef) does not work, but integer, parameter, dimension(5) :: & TCg_bband_coef_ranks = (/ ubound(TCg_coef,1), ubound(TCg_coef,2), ... /) works (if you fill the ...) and also the following works: integer, dimension(5) :: & TCg_bband_coef_ranks = ubound(TCg_coef) > If I comment out the assignment statement > from TCg_bband_coef_ranks to rank, then it compiles, but does it > actually work? Is this program deceiving in that it compiles, but > underneath, is actually not working? That's not good! I *think* I see what you mean. When I say "it doesn't work", I mean "it doesn't work if you try to use that PARAMETER later". When a PARAMETER is unused, the missing bit of code inside gfortran is not triggered, and there's no failure to compile. So it's not deveiving in the sense of "compiling but not working". -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31591
next prev parent reply other threads:[~2007-04-17 22:22 UTC|newest] Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top 2007-04-16 18:37 [Bug fortran/31591] New: internal compiler error on array initialization statement using 'ubound' Catherine dot M dot Moroney at jpl dot nasa dot gov 2007-04-16 19:05 ` [Bug fortran/31591] " dfranke at gcc dot gnu dot org 2007-04-16 19:07 ` Catherine dot M dot Moroney at jpl dot nasa dot gov 2007-04-16 19:42 ` [Bug fortran/31591] ICE: on array initialization statement using 'ubound' (fortran/trans-array.c:3693) dfranke at gcc dot gnu dot org 2007-04-16 20:14 ` burnus at gcc dot gnu dot org 2007-04-17 21:48 ` [Bug fortran/31591] UBOUND as initialization expression (lacking simplification) fxcoudert at gcc dot gnu dot org 2007-04-17 22:09 ` Catherine dot M dot Moroney at jpl dot nasa dot gov 2007-04-17 22:22 ` fxcoudert at gcc dot gnu dot org [this message] 2007-04-17 22:51 ` fxcoudert at gcc dot gnu dot org 2007-04-17 23:08 ` fxcoudert at gcc dot gnu dot org 2007-04-17 23:13 ` Catherine dot M dot Moroney at jpl dot nasa dot gov 2007-04-29 15:22 ` fxcoudert at gcc dot gnu dot org 2007-04-29 16:04 ` fxcoudert at gcc dot gnu dot org 2007-04-29 16:36 ` fxcoudert at gcc dot gnu dot 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=20070417222249.16049.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).