]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - libgfortran/m4/iforeach.m4
re PR libfortran/19106 ([4.0 only] segfault in executable for print *,sum(a,dim=2...
[thirdparty/gcc.git] / libgfortran / m4 / iforeach.m4
index 616caf94621c1767f9f354f01390cdedc789c4e8..39af3afef0936825ed6d9c7ca7cc2ad4a9cd9847 100644 (file)
@@ -43,6 +43,9 @@ name`'rtype_qual`_'atype_code (rtype * retarray, atype *array)
       if (retarray->dim[0].stride == 0)
        retarray->dim[0].stride = 1;
     }
+
+  /* TODO:  It should be a front end job to correctly set the strides.  */
+
   if (array->dim[0].stride == 0)
     array->dim[0].stride = 1;
 
@@ -151,9 +154,14 @@ void
        retarray->dim[0].stride = 1;
     }
 
+  /* TODO:  It should be a front end job to correctly set the strides.  */
+
   if (array->dim[0].stride == 0)
     array->dim[0].stride = 1;
 
+  if (mask->dim[0].stride == 0)
+    mask->dim[0].stride = 1;
+
   dstride = retarray->dim[0].stride;
   dest = retarray->data;
   for (n = 0; n < rank; n++)