diff options
author | Daniel Franke <franke.daniel@gmail.com> | 2009-06-06 17:09:57 -0400 |
---|---|---|
committer | Tobias Burnus <burnus@gcc.gnu.org> | 2009-06-06 23:09:57 +0200 |
commit | f7cfd28c03650adee94bf775ef7b88156ac9e70e (patch) | |
tree | 6461a1a3ba9b0a3a1a595f3cf0693b8f544bb7a7 /gcc/fortran | |
parent | 7ba8c18c1eb8ab48d44a9735c9974ae09b8dd9d4 (diff) | |
download | gcc-f7cfd28c03650adee94bf775ef7b88156ac9e70e.zip gcc-f7cfd28c03650adee94bf775ef7b88156ac9e70e.tar.gz gcc-f7cfd28c03650adee94bf775ef7b88156ac9e70e.tar.bz2 |
re PR fortran/37203 (Check ORDER= of RESHAPE)
2009-06-06 Daniel Franke <franke.daniel@gmail.com>
PR fortran/37203
* simplify.c (gfc_simplify_reshape): Fixed reshaping of empty
* arrays
without padding.
2009-06-06 Daniel Franke <franke.daniel@gmail.com>
PR fortran/37203
* reshape_zerosize_2.f90: New.
From-SVN: r148238
Diffstat (limited to 'gcc/fortran')
-rw-r--r-- | gcc/fortran/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/fortran/simplify.c | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index b50949f..711367a 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,5 +1,11 @@ 2009-06-06 Daniel Franke <franke.daniel@gmail.com> + PR fortran/37203 + * simplify.c (gfc_simplify_reshape): Fixed reshaping of empty arrays + without padding. + +2009-06-06 Daniel Franke <franke.daniel@gmail.com> + PR fortran/32890 * intrinsic.h (gfc_simplify_pack): New prototype. * intrinsic.c (add_functions): Added diff --git a/gcc/fortran/simplify.c b/gcc/fortran/simplify.c index 09cf297..737f299 100644 --- a/gcc/fortran/simplify.c +++ b/gcc/fortran/simplify.c @@ -3808,7 +3808,7 @@ gfc_simplify_reshape (gfc_expr *source, gfc_expr *shape_exp, for (i = 0; i < rank; i++) x[i] = 0; - for (;;) + while (nsource > 0 || npad > 0) { /* Figure out which element to extract. */ mpz_set_ui (index, 0); |