From f2adfb898bc52d3b83efbe03a94df4d6bc8663ad Mon Sep 17 00:00:00 2001 From: Jakub Jelinek Date: Tue, 30 Jan 2018 23:57:51 +0100 Subject: [PATCH] re PR debug/84131 (Fortran dynamical array debug info) PR debug/84131 * trans-array.c (gfc_get_descriptor_offsets_for_info): Set *data_off to DATA_FIELD's offset rather than OFFSET_FIELD's offset. From-SVN: r257212 --- gcc/fortran/ChangeLog | 6 ++++++ gcc/fortran/trans-array.c | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 35894cda5d0..3613d855a38 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,9 @@ +2018-01-30 Jakub Jelinek + + PR debug/84131 + * trans-array.c (gfc_get_descriptor_offsets_for_info): Set *data_off + to DATA_FIELD's offset rather than OFFSET_FIELD's offset. + 2017-01-30 Thomas Koenig PR fortran/84134 diff --git a/gcc/fortran/trans-array.c b/gcc/fortran/trans-array.c index c16b8754fa3..40703419d51 100644 --- a/gcc/fortran/trans-array.c +++ b/gcc/fortran/trans-array.c @@ -511,7 +511,7 @@ gfc_get_descriptor_offsets_for_info (const_tree desc_type, tree *data_off, tree type; type = TYPE_MAIN_VARIANT (desc_type); - field = gfc_advance_chain (TYPE_FIELDS (type), OFFSET_FIELD); + field = gfc_advance_chain (TYPE_FIELDS (type), DATA_FIELD); *data_off = byte_position (field); field = gfc_advance_chain (TYPE_FIELDS (type), DTYPE_FIELD); *dtype_off = byte_position (field); -- 2.30.2