This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug fortran/23019] New: Fortran string comparisons incorrectly treat trailing blanks as significant
- From: "James.A.Paget at aero dot org" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Fri, 30 Mar 2018 01:24:49 +0000
- Subject: [Bug fortran/23019] New: Fortran string comparisons incorrectly treat trailing blanks as significant
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=23019
Bug ID: 23019
Summary: Fortran string comparisons incorrectly treat trailing
blanks as significant
Product: gdb
Version: 7.12
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: fortran
Assignee: unassigned at sourceware dot org
Reporter: James.A.Paget at aero dot org
Target Milestone: ---
Created attachment 10926
--> https://sourceware.org/bugzilla/attachment.cgi?id=10926&action=edit
A screen capture that demonstrates the bug. It includes a listing of the
program used to demonstrate the bug.
This behavior has been observed both on HP-UX (an old version from ca. 2012)
and on the gfortran/gdb provided by equation.com for use on Windows. On Windows
7 Professional I am using gdb 7.12 and a nightly build of gfortran 8.00 from
20171029.
If you have a character*8 string x = 'a ' and another character*8 string
y = 'a', then the debugger will incorrectly report that x(1:4) .eq. x evaluates
to .FALSE. and that x(1:4) .eq. y(1:1) evaluates to .FALSE.. In fact, they
both evaluate to .TRUE., as shown by the program output, since as per the ANSI
Fortran 90 standard trailing blanks are not treated as significant in string
comparisons.
--
You are receiving this mail because:
You are on the CC list for the bug.