[gcc(refs/users/mikael/heads/refactor_descriptor_v206.01)] Ajout assertion

Mikael Morin via Gcc-cvs <[email protected]>
Newsgroups gmane.comp.gcc.cvs
Message-ID <[email protected]>
https://gcc.gnu.org/g:c470285138d4a0d25e297ecda7b32458dae1c1f3

commit c470285138d4a0d25e297ecda7b32458dae1c1f3
Author: Mikael Morin <[email protected]>
Date:   Thu Aug 20 13:24:45 2026 +0200

    Ajout assertion
    
    Correction macro assertion

Diff:
---
 gcc/fortran/trans-descriptor.cc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gcc/fortran/trans-descriptor.cc b/gcc/fortran/trans-descriptor.cc
index a70b926c2585..7a75b718f321 100644
--- a/gcc/fortran/trans-descriptor.cc
+++ b/gcc/fortran/trans-descriptor.cc
@@ -938,6 +938,7 @@ gfc_set_descriptor_from_scalar_class (stmtblock_t *block, tree descr,
   tree tmp = scalar;
   if (is_class_container_type (TREE_TYPE (tmp)))
     tmp = gfc_class_data_get (tmp);
+  gcc_assert (POINTER_TYPE_P (TREE_TYPE (tmp)));
 
   gfc_conv_descriptor_data_set (block, descr, tmp);
 }
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.