public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/99982] New: INTERFACE selects wrong module procedure involving C_PTR and C_FUNPTR
@ 2021-04-09  3:02 brtnfld at hdfgroup dot org
  2021-04-21  4:53 ` [Bug fortran/99982] " brtnfld at hdfgroup dot org
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: brtnfld at hdfgroup dot org @ 2021-04-09  3:02 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99982

            Bug ID: 99982
           Summary: INTERFACE selects wrong module procedure involving
                    C_PTR and C_FUNPTR
           Product: gcc
           Version: 10.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: brtnfld at hdfgroup dot org
  Target Milestone: ---

Created attachment 50532
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=50532&action=edit
program uses interface and module procedure to select between subroutines with
type C_PTR and C_FUNPTR

The attached program always selects the TYPE(C_FUNPTR) when selecting between a
(overloaded) subroutine with TYPE(C_PTR) and TYPE(C_FUNPTR), even when the
variable type is TYPE(C_PTR).

It does this for both passing a variable as the argument or using the C_LOC or
c_funloc directly in the call.

I tried it with 7.5.0, 10.2.0, same behavior.
Intel and NAG both select the correct subroutine.

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2023-05-16 13:25 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-09  3:02 [Bug fortran/99982] New: INTERFACE selects wrong module procedure involving C_PTR and C_FUNPTR brtnfld at hdfgroup dot org
2021-04-21  4:53 ` [Bug fortran/99982] " brtnfld at hdfgroup dot org
2022-04-20 16:24 ` thierry at FreeBSD dot org
2022-04-20 19:19 ` anlauf at gcc dot gnu.org
2023-03-22 16:41 ` brtnfld at hdfgroup dot org
2023-03-22 17:08 ` brtnfld at hdfgroup dot org
2023-04-11 14:56 ` anlauf at gcc dot gnu.org
2023-04-12  9:14 ` cvs-commit at gcc dot gnu.org
2023-04-12  9:21 ` anlauf at gcc dot gnu.org
2023-04-12 13:56 ` brtnfld at hdfgroup dot org
2023-04-23 18:53 ` cvs-commit at gcc dot gnu.org
2023-05-16 13:25 ` brtnfld at hdfgroup dot org

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).