With compiler
gcc version 4.3.0 20080109 (experimental) [trunk revision 131426] (GCC)
I get the following error message
>gfortran vf0009.f
vf0009.f: In function 'vf0009':
vf0009.f:11: error: size of variable 'test_array' is too large
If I replace the second line in the declaration of test_array with
any of
$ KIND(IDA1):5,
$ KIND(YDA):9,
$ 8:5,
the program compiles without an error message.
The LBOUND function is needed to trigger the error message
Dick Hendrickson
SUBROUTINE VF0009(IDA1,IDA2,YDA,HDA)
INTEGER(4) IDA1(4)
INTEGER(4) IDA2(4)
COMPLEX(8) YDA(2)
INTEGER(4) HDA(3)
! I N I T I A L I Z A T I O N S E C T I O N
COMPLEX(KIND=4) :: TEST_ARRAY
$( 4:5,
$ KIND(YDA):5,
$ 4:5,
$ 4:5 )
! T E S T S T A T E M E N T S
IDA1(1:4) = LBOUND(TEST_ARRAY)
END SUBROUTINE
--
Summary: LBOUND fails for array with KIND(complex) used in zero-
sized dimension
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: dick dot hendrickson at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34945