This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/49430] New: ICE with allocatable length character in interface block
- From: "shadowblade at altern dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 15 Jun 2011 23:14:15 +0000
- Subject: [Bug fortran/49430] New: ICE with allocatable length character in interface block
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49430
Summary: ICE with allocatable length character in interface
block
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: shadowblade@altern.org
The following code:
module mod_test3
abstract interface
function messageProcedure(code) result(message)
integer, intent(in) :: code
character(:), allocatable :: message
end function
end interface
type, public :: ctype
procedure(messageProcedure), pointer, nopass :: getMessage => null()
end type
contains
subroutine asub(this, num)
class(ctype), intent(in) :: this
integer, intent(in) :: num
character(:), allocatable :: message
if(associated(this%getMessage)) message = this%getMessage(num)
end subroutine
end module
causes this:
â
In function âasubâ:
Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
gfortran version:
Using built-in specs.
COLLECT_GCC=gfortran47
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/x86_64-apple-darwin10.6.0/4.7.0/lto-wrapper
Target: x86_64-apple-darwin10.6.0
Configured with: ../gcc-4.7-20110611/configure --program-suffix=47
--prefix=/usr/local/ : (reconfigured) ../gcc-4.7-20110611/configure
--program-suffix=47 --prefix=/usr/local/ --enable-lto
--enable-languages=c,c++,objc,obj-c++,fortran
Thread model: posix
gcc version 4.7.0 20110611 (experimental) (GCC)