OSDN Git Service

* trans-array.c (gfc_conv_loop_setup): Also skip temporary arrays.
authormikael <mikael@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 3 Nov 2011 21:14:19 +0000 (21:14 +0000)
committermikael <mikael@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 3 Nov 2011 21:14:19 +0000 (21:14 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@180853 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/fortran/ChangeLog
gcc/fortran/trans-array.c

index e9d3f81..c0fe2c0 100644 (file)
@@ -1,5 +1,9 @@
 2011-11-03  Mikael Morin  <mikael@gcc.gnu.org>
 
+       * trans-array.c (gfc_conv_loop_setup): Also skip temporary arrays.
+
+2011-11-03  Mikael Morin  <mikael@gcc.gnu.org>
+
        * trans-array.c (gfc_conv_ss_startstride): Access array bounds along
        array dimensions instead of loop dimensions.
 
index f4d8a85..cfbe909 100644 (file)
@@ -3881,7 +3881,12 @@ gfc_conv_loop_setup (gfc_loopinfo * loop, locus * where)
         loop for this dimension.  We try to pick the simplest term.  */
       for (ss = loop->ss; ss != gfc_ss_terminator; ss = ss->loop_chain)
        {
-         if (ss->type == GFC_SS_SCALAR || ss->type == GFC_SS_REFERENCE)
+         gfc_ss_type ss_type;
+
+         ss_type = ss->type;
+         if (ss_type == GFC_SS_SCALAR
+             || ss_type == GFC_SS_TEMP
+             || ss_type == GFC_SS_REFERENCE)
            continue;
 
          info = &ss->data.info;