This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/26041] New: FORTRAN compiler won't compile the valid code
- From: "hjl at lucon dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 31 Jan 2006 01:46:42 -0000
- Subject: [Bug fortran/26041] New: FORTRAN compiler won't compile the valid code
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
[hjl@gnu-16 cpu2006-465]$ cat foo.f90
module foo
public bar_
interface bar_
module procedure bar
end interface
public xxx_
interface xxx_
module procedure xxx
end interface
contains
subroutine xxx(self,z)
interface
function self(z) result(res)
real(kind=kind(1.0d0)), dimension(:) :: z
real(kind=kind(1.0d0)) :: res
end function
end interface
call bar_(self)
end subroutine
subroutine bar(self)
interface
function self(z) result(res)
real(kind=kind(1.0d0)) :: res
end function
end interface
end subroutine
end
[hjl@gnu-16 cpu2006-465]$ make
/export/build/gnu/gcc/build-x86_64-linux/gcc/gfortran
-B/export/build/gnu/gcc/build-x86_64-linux/gcc/ -O2 -S foo.f90
In file foo.f90:18
call bar_(self)
1
Error: Generic subroutine 'bar_' at (1) is not an intrinsic subroutine
make: *** [foo.s] Error 1
[hjl@gnu-16 cpu2006-465]$
Intel FORTRAN compiler has no problem. If I remove
real(kind=kind(1.0d0)), dimension(:) :: z
gfortran can compile it.
--
Summary: FORTRAN compiler won't compile the valid code
Product: gcc
Version: 4.2.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: hjl at lucon dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26041