From 46927ade0f5933c4eb22b049996fa15080b7f652 Mon Sep 17 00:00:00 2001 From: Tobias Burnus Date: Wed, 13 Nov 2019 11:13:57 +0000 Subject: PR fortran/92470 Fixes for CFI_address libgfortran/ PR fortran/92470 * runtime/ISO_Fortran_binding.c (CFI_establish): Set lower_bound to 0 also for CFI_attribute_other. gcc/testsuite/ PR fortran/92470 * gfortran.dg/ISO_Fortran_binding_1.c (establish_c): Add assert for lower_bound == 0. From-SVN: r278128 --- gcc/testsuite/ChangeLog | 6 ++++++ gcc/testsuite/gfortran.dg/ISO_Fortran_binding_1.c | 1 + 2 files changed, 7 insertions(+) (limited to 'gcc') diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 834c17a..1727bf0 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,9 @@ +2019-11-13 Tobias Burnus + + PR fortran/92470 + * gfortran.dg/ISO_Fortran_binding_1.c (establish_c): Add assert for + lower_bound == 0. + 2019-11-13 Richard Sandiford * gcc.target/aarch64/sve/mask_struct_store_3.c: Add diff --git a/gcc/testsuite/gfortran.dg/ISO_Fortran_binding_1.c b/gcc/testsuite/gfortran.dg/ISO_Fortran_binding_1.c index 091e754..a571459 100644 --- a/gcc/testsuite/gfortran.dg/ISO_Fortran_binding_1.c +++ b/gcc/testsuite/gfortran.dg/ISO_Fortran_binding_1.c @@ -109,6 +109,7 @@ int establish_c(CFI_cdesc_t * desc) CFI_attribute_pointer, CFI_type_struct, sizeof(t), 1, extent); + assert (desc->dim[0].lower_bound == 0); for (idx[0] = 0; idx[0] < extent[0]; idx[0]++) { res_addr = (t*)CFI_address (desc, idx); -- cgit v1.1