]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit - gdb/testsuite/ChangeLog
fort_dyn_array: Use value constructor instead of raw-buffer manipulation.
authorKeven Boell <keven.boell@intel.com>
Tue, 26 Apr 2016 14:46:48 +0000 (16:46 +0200)
committerBernhard Heckel <bernhard.heckel@intel.com>
Tue, 26 Apr 2016 14:48:41 +0000 (16:48 +0200)
commit3e2e34f8623d9eeb6710d8f3883f26af8b07bbd1
tree5e0cd224f61544b60893753d07faf23998512670
parent8f07e298b16e6419a11f9e9d75b15658e42ea775
fort_dyn_array: Use value constructor instead of raw-buffer manipulation.

Instead of pre-computing indices into a fortran array re-use
the value_* interfaces to subscript a fortran array.
The benefit of using the new interface is that it takes care of
dynamic types and resolve them when needed.
This fixes issues when printing structures with dynamic arrays from toplevel.

Before:
(gdb) p twov
$1 = ( (( ( 6352320, 0, -66, -1, 267) ( 343476, 1, -15, 1, 0) ( 5, 0, 5, 0, 1) ...

After:
(gdb) p twov
$1 = ( (( ( 1, 1, 1, 1, 1) ( 1, 1, 321, 1, 1) ( 1, 1, 1, 1, 1) ...

2016-04-26  Sanimir Agovic  <sanimir.agovic@intel.com>
            Keven Boell  <keven.boell@intel.com>
            Bernhard Heckel  <bernhard.heckel@intel.com>

gdb/Changelog:
* f-valprint.c (f77_create_arrayprint_offset_tbl): Remove
function.
(F77_DIM_SIZE, F77_DIM_OFFSET): Remove macro.
(f77_print_array_1): Use value_subscript to subscript a
value array.
(f77_print_array): Remove call to f77_create_arrayprint_offset_tbl.
(f_val_print): Use value_field to construct a field value.

gdb/testsuite/Changelog:
* vla-type.exp: Print structure from toplevel.
gdb/ChangeLog
gdb/f-valprint.c
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.fortran/vla-type.exp