public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: Michel Busquet (Forn_Natl) <busquet@this.nrl.navy.mil> To: gcc-bugs@gcc.gnu.org Cc: michel.busquet@free.fr Subject: Fortran compilation bug Date: Thu, 12 Aug 2004 14:57:00 -0000 [thread overview] Message-ID: <DCB9BECC-EC6F-11D8-96A9-0003938D981E@this.nrl.navy.mil> (raw) The following source file produce an error at compilation time about alleged "undefined length" string Source file: ---------------- program a character ch*10 ch='abcd' call b(ch) stop end c subroutine b(ch) character ch*(*) integer i,l do i=1,len(ch) l=i if(ch(i:i).eq.' ') goto 1 enddo 1 call C(ch(1:l)//'ok') return end c subroutine C(ch) print *,ch return end Compilation command line and messages : ----------------------------------------------------------- $ g77 -o a.out a.f a.f: In subroutine `b': a.f:15: 1 call C(ch(1:l)//'ok') 1 2 Concatenation operator at (2) must operate on two scalar (not array) subexpressions, two function invocations returning character scalars, or a combination of both -- but the subexpression at (1) is of indeterminate length a.f: In subroutine `c': a.f:15: warning: 1 call C(ch(1:l)//'ok') 1 a.f:19: (continued): subroutine C(ch) 2 Argument #1 (named `ch') of `c' is one type at (2) but is some other type at (1) [info -f g77 M GLOBALS] Gcc Version: ----------------- gcc -v Reading specs from /usr/libexec/gcc/darwin/ppc/3.3/specs Thread model: posix gcc version 3.3 20030304 (Apple Computer, Inc. build 1495) Platform and system: ---------------------------- iMac + Mac OS X 10.3
next reply other threads:[~2004-08-12 14:57 UTC|newest] Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top 2004-08-12 14:57 Michel Busquet [this message] 2004-08-16 21:49 ` James E Wilson
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=DCB9BECC-EC6F-11D8-96A9-0003938D981E@this.nrl.navy.mil \ --to=busquet@this.nrl.navy.mil \ --cc=gcc-bugs@gcc.gnu.org \ --cc=michel.busquet@free.fr \ /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).