re PR fortran/85111 (ICE in min_max_choose, at fortran/simplify.c:4884 (and others))
authorThomas Koenig <tkoenig@gcc.gnu.org>
Fri, 30 Mar 2018 09:56:46 +0000 (09:56 +0000)
committerThomas Koenig <tkoenig@gcc.gnu.org>
Fri, 30 Mar 2018 09:56:46 +0000 (09:56 +0000)
commit1832cbf8905a5d24075fc7b2aad495ec0e05cbdf
tree9d6078e8de36849ab7fc144cb5f8f8ff09b58bed
parent06be18e782b9497ffda6523786a38f13f1412e36
re PR fortran/85111 (ICE in min_max_choose, at fortran/simplify.c:4884 (and others))

2017-03-30  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/85111
* array.c (gfc_resolve_character_array_constructor): Early
exit for zero-size arrays.
* simplify.c (simplify_transformation_to_array): Exit early
if the result size is zero.
(simplify_minmaxloc_to_array): Likewise.

2017-03-30  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/85111
* gfortran.dg/zero_sized_10.f90: New test.

From-SVN: r258973
gcc/fortran/array.c
gcc/fortran/simplify.c
gcc/testsuite/gfortran.dg/zero_sized_10.f90 [new file with mode: 0644]