https://gcc.gnu.org/g:7818e31b1ca1ea4796040325332a850765ef9fdd

commit 7818e31b1ca1ea4796040325332a850765ef9fdd
Author: Mikael Morin <mik...@gcc.gnu.org>
Date:   Thu Jan 16 14:51:42 2025 +0100

    Factorisation shift descriptor

Diff:
---
 gcc/fortran/trans-expr.cc | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/gcc/fortran/trans-expr.cc b/gcc/fortran/trans-expr.cc
index 77e8a55af457..b7d1e3df0613 100644
--- a/gcc/fortran/trans-expr.cc
+++ b/gcc/fortran/trans-expr.cc
@@ -1219,7 +1219,6 @@ gfc_conv_intrinsic_to_class (gfc_se *parmse, gfc_expr *e,
   tree ctree;
   tree var;
   tree tmp;
-  int dim;
   bool unlimited_poly;
 
   unlimited_poly = class_ts.type == BT_CLASS
@@ -1287,11 +1286,7 @@ gfc_conv_intrinsic_to_class (gfc_se *parmse, gfc_expr *e,
          /* Array references with vector subscripts and non-variable 
expressions
             need be converted to a one-based descriptor.  */
          if (e->expr_type != EXPR_VARIABLE)
-           {
-             for (dim = 0; dim < e->rank; ++dim)
-               gfc_conv_shift_descriptor_lbound (&parmse->pre, parmse->expr,
-                                                 dim, gfc_index_one_node);
-           }
+           gfc_conv_shift_descriptor (&parmse->pre, parmse->expr, e->rank);
 
          if (class_ts.u.derived->components->as->rank != e->rank)
            {

Reply via email to