https://gcc.gnu.org/g:45a3a2c3b4ba949577f7c6f8d059d20041486989
commit 45a3a2c3b4ba949577f7c6f8d059d20041486989 Author: Mikael Morin <[email protected]> Date: Fri Oct 3 17:36:45 2025 +0200 Correction régression class_array_22.f03 Diff: --- gcc/fortran/trans-array.cc | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gcc/fortran/trans-array.cc b/gcc/fortran/trans-array.cc index d32102383a12..2ed407da0a2d 100644 --- a/gcc/fortran/trans-array.cc +++ b/gcc/fortran/trans-array.cc @@ -7031,7 +7031,12 @@ gfc_trans_dummy_array_bias (gfc_symbol * sym, tree tmpdesc, TREE_USED (partial) = 1; tree packed_stride; if (GFC_BYTES_STRIDES_ARRAY_TYPE_P (TREE_TYPE (dumdesc))) - packed_stride = gfc_conv_descriptor_elem_len_get (dumdesc); + { + packed_stride = gfc_conv_descriptor_elem_len_get (dumdesc); + packed_stride = fold_convert_loc (input_location, + gfc_array_index_type, + packed_stride); + } else packed_stride = gfc_index_one_node; tree stride = gfc_conv_descriptor_stride_get (dumdesc, 0);
