public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/64474] New: transfer(c_null_ptr, ...) causes an internal error
@ 2015-01-02 15:14 arjen.markus895 at gmail dot com
  2015-01-02 15:28 ` [Bug fortran/64474] [4.8 Regression] " janus at gcc dot gnu.org
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: arjen.markus895 at gmail dot com @ 2015-01-02 15:14 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 64474
           Summary: transfer(c_null_ptr, ...) causes an internal error
           Product: gcc
           Version: 4.8.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: arjen.markus895 at gmail dot com

I needed to pass a null pointer from Fortran to C. One attempt to do so was via
code like this:

module myinterfaces
    use iso_c_binding
    implicit none

    interface
        subroutine croutine( array ) bind(c,name='croutine')
            real, dimension(*) :: array
        end subroutine
    end interface
contains

subroutine myroutine
    real, dimension(1) :: dummy
    call croutine( transfer(c_null_ptr, dummy) )
end subroutine myroutine

end module myinterfaces

This causes an internal error:

f951: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.


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

end of thread, other threads:[~2015-02-11 14:31 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-02 15:14 [Bug fortran/64474] New: transfer(c_null_ptr, ...) causes an internal error arjen.markus895 at gmail dot com
2015-01-02 15:28 ` [Bug fortran/64474] [4.8 Regression] " janus at gcc dot gnu.org
2015-01-02 22:06 ` arjen.markus895 at gmail dot com
2015-01-09 11:31 ` rguenth at gcc dot gnu.org
2015-01-23 19:25 ` dominiq at lps dot ens.fr
2015-02-11 14:31 ` burnus 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).