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/35161] New: Bind(C): Procedures with different interface and same C binding label Date: Mon, 11 Feb 2008 08:55:00 -0000 [thread overview] Message-ID: <bug-35161-13404@http.gcc.gnu.org/bugzilla/> (raw) I think it is formally valid to have multiple times the same C binding label (at least for procedures). At least I cannot find anything in the standard which says otherwise. Currently, both gfortran and NAG f95 reject the following program while g95 and ifort accept it. See also question posted at: http://groups.google.com/group/comp.lang.fortran/browse_thread/thread/b1e8c8d0af9d16e8/ (when writing this, the question was not yet answered) NAG f95: Error: aaa.f90: Duplicate binding label 'xxx' for external procedure XXX_1 and external procedure XXX_2 gfortran: Error: Binding label 'xxx' in interface body at (1) collides with the global entity 'xxx' at (2) interface xxx integer function xxx_1( y ) bind( c, name = "xxx" ) use iso_c_binding real(c_float), intent(inout) :: y end function integer function xxx_2( y ) bind( c, name = "xxx" ) use iso_c_binding real(c_float), intent(inout), dimension(*) :: y end function end interface end -- Summary: Bind(C): Procedures with different interface and same C binding label Product: gcc Version: 4.3.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: burnus at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35161
next reply other threads:[~2008-02-11 8:55 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2008-02-11 8:55 burnus at gcc dot gnu dot org [this message] 2008-02-12 20:06 ` [Bug fortran/35161] " dfranke at gcc dot gnu dot org 2009-01-03 23:00 ` dfranke at gcc dot gnu dot org 2009-01-04 0:49 ` dfranke at gcc dot gnu dot org 2009-03-29 8:02 ` [Bug fortran/35161] Add warning about procedures with same C binding label and different interface fxcoudert at gcc dot gnu dot org 2010-05-09 13:15 ` dfranke at gcc dot gnu dot org 2010-05-09 14:08 ` dfranke at gcc dot gnu dot org 2010-05-09 14:10 ` [Bug fortran/35161] [F2008] allow procedures with same binding label (invalid in F2003) dfranke 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=bug-35161-13404@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).