[Bug fortran/36371] New: [4.3/4.4 Regression] Wrong locus for errors in DATA statement
dominiq at lps dot ens dot fr
gcc-bugzilla@gcc.gnu.org
Thu May 29 14:19:00 GMT 2008
The first test case in PR36319 gives now:
character(len=3, kind=4), parameter, dimension(3) :: mychar = [ "abc", "def
1
Error: Incompatible types in assignment at (1); attempted assignment of
CHARACTER(4) to CHARACTER(1)
which does not look right. The following codelet from FX:
program chkdata
character(len=3), parameter :: mychar(3) = [ "abc", "def", "ghi" ]
integer :: c(5)
data c / mychar(1), mychar(2), mychar(3), mychar(1), mychar(2) /
end program chkdata
gives with gfortran 4.3/4.4:
character(len=3), parameter :: mychar(3) = [ "abc", "def", "ghi" ]
1
Error: Incompatible types in assignment at (1); attempted assignment of
CHARACTER(1) to INTEGER(4)
but with gfortran 4.2:
data c / mychar(1), mychar(2), mychar(3), mychar(1), mychar(2) /
1
Error: Syntax error in DATA statement at (1)
pointing to the right locus of the error.
--
Summary: [4.3/4.4 Regression] Wrong locus for errors in DATA
statement
Product: gcc
Version: 4.4.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: dominiq at lps dot ens dot fr
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36371
More information about the Gcc-bugs
mailing list