public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/63363] New: No diagnostic for passing function as actual argument to KIND
@ 2014-09-25  2:55 ian_harvey at bigpond dot com
  2014-12-21  9:30 ` [Bug fortran/63363] " janus at gcc dot gnu.org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: ian_harvey at bigpond dot com @ 2014-09-25  2:55 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 63363
           Summary: No diagnostic for passing function as actual argument
                    to KIND
           Product: gcc
           Version: 5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ian_harvey at bigpond dot com

The following (from recent c.l.f discussion) compiles without error with trunk
r215574, despite the actual argument not meeting the requirements for the
argument of the KIND intrinsic (the argument must be a data entity).

    INTERFACE
      FUNCTION f()
        INTEGER(SELECTED_INT_KIND(4)) :: f
      END FUNCTION f
    END INTERFACE

    PRINT *, KIND(f)
  END

  ! (just to provide a definition)
  FUNCTION f()
    INTEGER(SELECTED_INT_KIND(4)) :: f
  END FUNCTION f 

After compiling (supplying no options) the resulting program, when executed,
prints zero.


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

end of thread, other threads:[~2014-12-22 18:17 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-25  2:55 [Bug fortran/63363] New: No diagnostic for passing function as actual argument to KIND ian_harvey at bigpond dot com
2014-12-21  9:30 ` [Bug fortran/63363] " janus at gcc dot gnu.org
2014-12-21  9:42 ` janus at gcc dot gnu.org
2014-12-21  9:59 ` janus at gcc dot gnu.org
2014-12-21 10:34 ` janus at gcc dot gnu.org
2014-12-22 18:15 ` janus at gcc dot gnu.org
2014-12-22 18:17 ` janus at gcc dot gnu.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).