public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/107406] New: lock_type
@ 2022-10-26  5:09 damian at archaeologic dot codes
  2022-10-27 14:25 ` [Bug fortran/107406] lock_type kargl at gcc dot gnu.org
  0 siblings, 1 reply; 2+ messages in thread
From: damian at archaeologic dot codes @ 2022-10-26  5:09 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 107406
           Summary: lock_type
           Product: gcc
           Version: 12.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: damian at archaeologic dot codes
  Target Milestone: ---

gfortran 12.2 accepts the code below if the "allocatable" attribute is removed:

% cat gfortran-lock-issue.f90 
  use iso_fortran_env
  type foo
    type(lock_type), allocatable :: bar
  end type
  type(foo) foobar[*]
end

% gfortran -fcoarray=single gfortran-lock-issue.f90 
gfortran-lock-issue.f90:3:39:

    3 |     type(lock_type), allocatable :: bar
      |                                       1
Error: Allocatable component bar at (1) of type LOCK_TYPE must have a
codimension

The NAG compiler accepts the above code and I believe constraint C1608 in the
Fortran 2018 standard makes the above code valid.

Is this related to PR 92122?

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-10-27 14:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-26  5:09 [Bug fortran/107406] New: lock_type damian at archaeologic dot codes
2022-10-27 14:25 ` [Bug fortran/107406] lock_type kargl at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).