summaryrefslogtreecommitdiff
path: root/libgfortran/generated/maxloc0_8_s4.c
diff options
context:
space:
mode:
Diffstat (limited to 'libgfortran/generated/maxloc0_8_s4.c')
-rw-r--r--libgfortran/generated/maxloc0_8_s4.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/libgfortran/generated/maxloc0_8_s4.c b/libgfortran/generated/maxloc0_8_s4.c
index 60176b4bbb9..fc28686976b 100644
--- a/libgfortran/generated/maxloc0_8_s4.c
+++ b/libgfortran/generated/maxloc0_8_s4.c
@@ -174,6 +174,16 @@ mmaxloc0_8_s4 (gfc_array_i8 * const restrict retarray,
index_type n;
int mask_kind;
+ if (mask == NULL)
+ {
+#ifdef HAVE_BACK_ARG
+ maxloc0_8_s4 (retarray, array, back, len);
+#else
+ maxloc0_8_s4 (retarray, array, len);
+#endif
+ return;
+ }
+
rank = GFC_DESCRIPTOR_RANK (array);
if (rank <= 0)
runtime_error ("Rank of array needs to be > 0");
@@ -304,7 +314,7 @@ smaxloc0_8_s4 (gfc_array_i8 * const restrict retarray,
index_type n;
GFC_INTEGER_8 *dest;
- if (*mask)
+ if (mask == NULL || *mask)
{
#ifdef HAVE_BACK_ARG
maxloc0_8_s4 (retarray, array, back, len);