public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/53191] New: [OOP] C614 (F2003) or C618 (F2008) not implemented for class expressions
@ 2012-05-02 14:19 pault at gcc dot gnu.org
  2012-05-05  8:51 ` [Bug fortran/53191] " pault at gcc dot gnu.org
  2012-05-05  8:55 ` pault at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: pault at gcc dot gnu.org @ 2012-05-02 14:19 UTC (permalink / raw)
  To: gcc-bugs

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

             Bug #: 53191
           Summary: [OOP] C614 (F2003) or C618 (F2008) not implemented for
                    class expressions
    Classification: Unclassified
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: pault@gcc.gnu.org


"A part-name to the right of a part-ref with non-zero rank shall not have the
POINTER or ALLOCATABLE attribute" is not implemented for class expressions.

 implicit none
 type t0
   integer :: j = 42
 end type t0
 type, extends(t0) :: t1
   integer :: k = 99
 end type t1
 type t
   integer :: i
   class(t0), allocatable :: foo
 end type t
 type(t) :: m(4)
 integer :: n

 do n = 1, 2
   allocate(m(n)%foo, source = t0(n*99))
 end do
 do n = 3, 4
   allocate(m(n)%foo, source = t1(n*99, n*999))
 end do

end

Should not be permitted, according to this constraint. At present, it compiles
and does the intended thing at runtime.

Cheers

Paul


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

end of thread, other threads:[~2012-05-05  8:54 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-05-02 14:19 [Bug fortran/53191] New: [OOP] C614 (F2003) or C618 (F2008) not implemented for class expressions pault at gcc dot gnu.org
2012-05-05  8:51 ` [Bug fortran/53191] " pault at gcc dot gnu.org
2012-05-05  8:55 ` pault 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).