public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/56423] New: F08/0071: Shall reject invalid Vector subscript target with Pointer assignment
@ 2013-02-21 21:25 burnus at gcc dot gnu.org
  2015-10-10 10:28 ` [Bug fortran/56423] " dominiq at lps dot ens.fr
  0 siblings, 1 reply; 2+ messages in thread
From: burnus at gcc dot gnu.org @ 2013-02-21 21:25 UTC (permalink / raw)
  To: gcc-bugs


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

             Bug #: 56423
           Summary: F08/0071: Shall reject invalid Vector subscript target
                    with Pointer assignment
    Classification: Unclassified
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Keywords: ice-on-invalid-code
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: burnus@gcc.gnu.org


Interp F08/0071, http://www.j3-fortran.org/doc/year/13/13-250.txt

Note: The J3/WG5 vote is still pending.


Case (4) of the test case below is invalid per clarified constraint F2008,
C724:

  "A variable that is a pointer target shall have either the TARGET
   or POINTER attribute, and shall not be an array section with a
   vector subscript."

Currently, gfortran ICEs with:
internal compiler error: in gfc_conv_expr_descriptor, at
fortran/trans-array.c:6589

  PROGRAM m197006
    REAL,TARGET :: x(100) = [ (i,i=1,100) ]
    REAL,POINTER :: p(:)
    TYPE t
      REAL,POINTER :: q(:)
    END TYPE
    TYPE(t) y
    p => x                     ! (1)
    y = t(x)                   ! (2)
!   p => x( [ 1,4,9,25 ] )     ! (3)  ! Invalid and rejected
    y = t(x( [ 1,4,9,25 ] ))   ! (4)  ! Invalid per IR F08/0071 but not
rejected
    PRINT *,y%q
  END PROGRAM


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

end of thread, other threads:[~2015-10-10 10:28 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-21 21:25 [Bug fortran/56423] New: F08/0071: Shall reject invalid Vector subscript target with Pointer assignment burnus at gcc dot gnu.org
2015-10-10 10:28 ` [Bug fortran/56423] " dominiq at lps dot ens.fr

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).