https://gcc.gnu.org/bugzilla/show_bug.cgi?id=129021

            Bug ID: 129021
           Summary: [F2023] The rank clause is unsupported
           Product: gcc
           Version: 17.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: mikael at gcc dot gnu.org
  Target Milestone: ---

Consider this:

  integer, allocatable, rank(1) :: a
end


It is rejected with the error:

    1 |   integer, allocatable, rank(1) :: a
      |           1
Error: Invalid character in name at (1)


But it is allowed, starting from f2023 it seems.

See 8.2 (Type declaration statement):
    R802 attr-spec    is access-spec
                      or ALLOCATABLE
                      (...)
                      or rank-clause
                      (...)
                      or VOLATILE

and 8.5.17 (RANK clause):
    R829 rank-clause    is RANK ( scalar-int-constant-expr )

Reply via email to