diff options
author | José Rui Faustino de Sousa <jrfsousa@gmail.com> | 2022-10-18 22:29:59 +0200 |
---|---|---|
committer | Harald Anlauf <anlauf@gmx.de> | 2022-10-21 20:17:43 +0200 |
commit | 4cfdaeb2755121ac1069f09898def56469b0fb51 (patch) | |
tree | f99a46e71c1126e3092037e4b8ae23eea8d46c17 /gcc/fortran/trans-array.h | |
parent | 5792208f5124f687376f25798668d105d7ddb270 (diff) | |
download | gcc-4cfdaeb2755121ac1069f09898def56469b0fb51.zip gcc-4cfdaeb2755121ac1069f09898def56469b0fb51.tar.gz gcc-4cfdaeb2755121ac1069f09898def56469b0fb51.tar.bz2 |
Fortran: Add missing TKR initialization to class variables [PR100097, PR100098]
gcc/fortran/ChangeLog:
PR fortran/100097
PR fortran/100098
* trans-array.cc (gfc_trans_class_array): New function to
initialize class descriptor's TKR information.
* trans-array.h (gfc_trans_class_array): Add function prototype.
* trans-decl.cc (gfc_trans_deferred_vars): Add calls to the new
function for both pointers and allocatables.
gcc/testsuite/ChangeLog:
PR fortran/100097
PR fortran/100098
* gfortran.dg/PR100097.f90: New test.
* gfortran.dg/PR100098.f90: New test.
Diffstat (limited to 'gcc/fortran/trans-array.h')
-rw-r--r-- | gcc/fortran/trans-array.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/fortran/trans-array.h b/gcc/fortran/trans-array.h index 04fee61..cd2b3d9 100644 --- a/gcc/fortran/trans-array.h +++ b/gcc/fortran/trans-array.h @@ -69,6 +69,8 @@ tree gfc_check_pdt_dummy (gfc_symbol *, tree, int, gfc_actual_arglist *); tree gfc_alloc_allocatable_for_assignment (gfc_loopinfo*, gfc_expr*, gfc_expr*); +/* Add initialization for class descriptors */ +void gfc_trans_class_array (gfc_symbol *, gfc_wrapped_block *); /* Add initialization for deferred arrays. */ void gfc_trans_deferred_array (gfc_symbol *, gfc_wrapped_block *); /* Generate an initializer for a static pointer or allocatable array. */ |