aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/array.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/fortran/array.c')
-rw-r--r--gcc/fortran/array.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/gcc/fortran/array.c b/gcc/fortran/array.c
index 71c8b5d..5593289 100644
--- a/gcc/fortran/array.c
+++ b/gcc/fortran/array.c
@@ -437,6 +437,12 @@ gfc_match_array_spec (gfc_array_spec **asp)
goto cleanup;
}
+ if (as->rank > 7
+ && gfc_notify_std (GFC_STD_F2008, "Fortran 2008: Array "
+ "specification at %C with more than 7 dimensions")
+ == FAILURE)
+ goto cleanup;
+
as->rank++;
}