This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/29916] New: Dimension of a function result as host association does not work
- From: "burnus at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 20 Nov 2006 18:12:52 -0000
- Subject: [Bug fortran/29916] New: Dimension of a function result as host association does not work
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
The following valid code by Marco Restelli,
http://gcc.gnu.org/ml/fortran/2006-11/msg00520.html
fails to compile with current gfortran 4.3:
host.f90:8.20:
real :: internal_f(n)
1
Error: Variable 'n' cannot appear in the expression at (1)
This program compiles with NAG f95, ifort, g95, sunf95 and Lahey.
----------------------------
program test_internal
implicit none
integer :: n
n = 4
contains
function internal_f()
real :: internal_f(n)
internal_f = 2
end function internal_f
end program test_internal
----------------------------
--
Summary: Dimension of a function result as host association does
not work
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Keywords: rejects-valid
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: burnus at gcc dot gnu dot org
GCC target triplet: x86_64-unknown-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29916