public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "kargl at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/50149] loader error with source containing common blocks Date: Fri, 02 Sep 2011 23:01:00 -0000 [thread overview] Message-ID: <bug-50149-4-m6xuHzIoGm@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-50149-4@http.gcc.gnu.org/bugzilla/> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50149 kargl at gcc dot gnu.org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kargl at gcc dot gnu.org Severity|major |normal --- Comment #4 from kargl at gcc dot gnu.org 2011-09-02 23:00:54 UTC --- (In reply to comment #3) > Hello, > > Thank you very much for your reply and help. > > Your example pointed me to the clue to find the error in my source: > evidently, a /name/ block is required even when the "name" is empty, > i.e., "common // ...", my source had "common i, j, k, ..." this is not > allowed! No, a /name/ block *IS NOT* required even when the name is empty. troutmask:sgk[218] cat a.f90 b.f90 c.f90 ! a.f90 subroutine foo common i i = 2 end subroutine foo ! b.f90 subroutine bar common j j = 1 end subroutine bar ! c.f90 program c common k call foo call bar print *, k end program c This compiles with gfortran 4.7.0 with all of the options you specify. > What is surprising is that no compiler error or warning was generated > while the loader complained! I had expected to get a compiler error if > the "common /name/ ..." format is strictly required. Perhaps you could > make a note to cause a compiler error in your future distributions. It's not required. You have a broken loader, which is not a gfortran problem.
next prev parent reply other threads:[~2011-09-02 23:01 UTC|newest] Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top 2011-08-22 6:58 [Bug fortran/50149] New: " riddle00 at gmail dot com 2011-08-22 13:52 ` [Bug fortran/50149] " burnus at gcc dot gnu.org 2011-08-22 14:07 ` dominiq at lps dot ens.fr 2011-09-02 22:35 ` riddle00 at gmail dot com 2011-09-02 23:01 ` kargl at gcc dot gnu.org [this message] 2013-06-29 21:32 ` dominiq at lps dot ens.fr
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-50149-4-m6xuHzIoGm@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: 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).