This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/35732] New: -fbounds-check: LHS/RHS size mismatch: Misleading error message
- 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: 28 Mar 2008 14:54:52 -0000
- Subject: [Bug fortran/35732] New: -fbounds-check: LHS/RHS size mismatch: Misleading error message
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
For
integer :: a(2)
integer, volatile :: i
i = 1
a(1:i) = a(1:2)
end
The message is misleading:
At line 4 of file aa.f90
Fortran runtime error: Array bound mismatch, size mismatch for dimension 1 of
array 'a' (0/1)
ISSUE:
The size should be "1/2" and not "0/1" (For a zero-sized array the output is
even "-1").
--
Summary: -fbounds-check: LHS/RHS size mismatch: Misleading error
message
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Keywords: diagnostic
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: burnus at gcc dot gnu dot org
OtherBugsDependingO 27766
nThis:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35732