https://gcc.gnu.org/g:0772b835b1f3c37c0ec5ea9e7554090bf164345c

commit 0772b835b1f3c37c0ec5ea9e7554090bf164345c
Author: Mikael Morin <mik...@gcc.gnu.org>
Date:   Thu Mar 13 11:08:37 2025 +0100

    Correction régression select_type_26.f03

Diff:
---
 gcc/fortran/trans-types.cc | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/gcc/fortran/trans-types.cc b/gcc/fortran/trans-types.cc
index 7c481490eb1c..ff43cb1522a0 100644
--- a/gcc/fortran/trans-types.cc
+++ b/gcc/fortran/trans-types.cc
@@ -3222,6 +3222,9 @@ gfc_get_derived_type (gfc_symbol * derived, int codimen)
        GFC_DECL_PTR_ARRAY_P (c->backend_decl) = 1;
     }
 
+  if (derived->attr.is_class)
+    GFC_CLASS_TYPE_P (typenode) = 1;
+
   /* Now lay out the derived type, including the fields.  */
   if (canonical)
     TYPE_CANONICAL (typenode) = canonical;

Reply via email to