aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/target-memory.h
diff options
context:
space:
mode:
authorHarald Anlauf <anlauf@gmx.de>2019-02-24 20:03:28 +0000
committerHarald Anlauf <anlauf@gcc.gnu.org>2019-02-24 20:03:28 +0000
commitcdd1793162ce3a8dc1c0d067f1af173eee98da0f (patch)
treef8023f584e66c89d7f50649bb609e9124f0aab15 /gcc/fortran/target-memory.h
parent953e25c44acc2458d854b1442d7775d997aaf187 (diff)
downloadgcc-cdd1793162ce3a8dc1c0d067f1af173eee98da0f.zip
gcc-cdd1793162ce3a8dc1c0d067f1af173eee98da0f.tar.gz
gcc-cdd1793162ce3a8dc1c0d067f1af173eee98da0f.tar.bz2
re PR fortran/89266 (ICE with TRANSFER of len=0 character array constructor)
2019-02-24 Harald Anlauf <anlauf@gmx.de> PR fortran/89266 PR fortran/88326 * target-memory.c (gfc_element_size): Return false if element size cannot be determined; element size is returned separately. (gfc_target_expr_size): Return false if expression size cannot be determined; expression size is returned separately. * target-memory.h: Adjust prototypes. * check.c (gfc_calculate_transfer_sizes): Adjust references to gfc_target_expr_size, gfc_element_size. * arith.c (hollerith2representation): Likewise. * class.c (find_intrinsic_vtab): Likewise. * simplify.c (gfc_simplify_sizeof): Likewise. PR fortran/89266 PR fortran/88326 * gfortran.dg/pr89266.f90: New test. * gfortran.dg/pr88326.f90: New test. From-SVN: r269177
Diffstat (limited to 'gcc/fortran/target-memory.h')
-rw-r--r--gcc/fortran/target-memory.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/fortran/target-memory.h b/gcc/fortran/target-memory.h
index 37ac22f..5e06c9a 100644
--- a/gcc/fortran/target-memory.h
+++ b/gcc/fortran/target-memory.h
@@ -24,8 +24,8 @@ along with GCC; see the file COPYING3. If not see
/* Convert a BOZ to REAL or COMPLEX. */
bool gfc_convert_boz (gfc_expr *, gfc_typespec *);
-size_t gfc_element_size (gfc_expr *);
-size_t gfc_target_expr_size (gfc_expr *);
+bool gfc_element_size (gfc_expr *, size_t *);
+bool gfc_target_expr_size (gfc_expr *, size_t *);
/* Write a constant expression in binary form to a target buffer. */
size_t gfc_encode_character (int, size_t, const gfc_char_t *, unsigned char *,