https://gcc.gnu.org/g:534f115e98596e153fda1665e59e4c07423205df

commit 534f115e98596e153fda1665e59e4c07423205df
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 cc5713c37eac..33f6bfbc5d85 100644
--- a/gcc/fortran/trans-types.cc
+++ b/gcc/fortran/trans-types.cc
@@ -3244,6 +3244,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