http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57458

Tobias Burnus <burnus at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Assignee|unassigned at gcc dot gnu.org      |burnus at gcc dot 
gnu.org

--- Comment #1 from Tobias Burnus <burnus at gcc dot gnu.org> ---
Draft patch

--- a/gcc/fortran/interface.c
+++ b/gcc/fortran/interface.c
@@ -2033,3 +2033,4 @@ compare_parameter (gfc_symbol *formal, gfc_expr *actual,
       && actual->rank && !gfc_is_simply_contiguous (actual, true)
-      && ((formal->as->type != AS_ASSUMED_SHAPE && !formal->attr.pointer)
+      && ((formal->as->type != AS_ASSUMED_SHAPE
+          && formal->as->type != AS_ASSUMED_RANK && !formal->attr.pointer)
          || formal->attr.contiguous))
@@ -2037,6 +2038,6 @@ compare_parameter (gfc_symbol *formal, gfc_expr *actual,
       if (where)
-       gfc_error ("Dummy argument '%s' has to be a pointer or assumed-shape "
-                  "array without CONTIGUOUS attribute - as actual argument at"
-                  " %L is not simply contiguous and both are ASYNCHRONOUS "
-                  "or VOLATILE", formal->name, &actual->where);
+       gfc_error ("Dummy argument '%s' has to be a pointer, assumed-shape or "
+                  "assumed-rank array without CONTIGUOUS attribute - as
actual"
+                  " argument at %L is not simply contiguous and both are "
+                  "ASYNCHRONOUS or VOLATILE", formal->name, &actual->where);
       return 0;

Reply via email to