This is the mail archive of the gdb-prs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/23182] New: gdb prints wrong contents of non-contiguous arrays


https://sourceware.org/bugzilla/show_bug.cgi?id=23182

            Bug ID: 23182
           Summary: gdb prints wrong contents of non-contiguous arrays
           Product: gdb
           Version: 8.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: fortran
          Assignee: unassigned at sourceware dot org
          Reporter: richard.foltyn at gmail dot com
  Target Milestone: ---

Created attachment 11017
  --> https://sourceware.org/bugzilla/attachment.cgi?id=11017&action=edit
code to replicate the example given

Hi,

gdb incorrectly prints the contents of array dummy arguments if the actual
argument is a non-contiguous array section.

For example, using the demo in main.f90, when inspecting the array X in
subroutine SUB1 in gdb, it prints
(gdb) p x
$1 = (( 1, 2) ( 3, 4) ( 5, 6) )

while the array contents printed using PRINT in that routine displays the
correct values
1, 2, 4, 5, 7, 8

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]