This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/49802] New: [F2008] Handle VALUE with arrays (DIMENSION)
- From: "burnus at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 21 Jul 2011 09:04:36 +0000
- Subject: [Bug fortran/49802] New: [F2008] Handle VALUE with arrays (DIMENSION)
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49802
Summary: [F2008] Handle VALUE with arrays (DIMENSION)
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Keywords: rejects-valid
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: burnus@gcc.gnu.org
Depends on: 35203
Blocks: 39627
Fortran 2008 relaxed the constrains with regards to VALUE. While Fortran 2003
only allowed it for objects which can be transferred by pass-by-value (in
sprite of BIND(C) dummys/C nonpointer parameters), Fortran 2003 now allows for
everything which may be copied in, which is nearly everything.
Fortran 2008 has:
C557 An entity with the VALUE attribute shall be a dummy data object
that is not an assumed-size array or a coarray, and does not have
a coarray ultimate component.
C558 An entity with the VALUE attribute shall not have the ALLOCATABLE,
INTENT (INOUT), INTENT(OUT), POINTER, or VOLATILE attributes.
Fortran 2003 has:
C527 (R501) If the VALUE attribute is specified, the PARAMETER, EXTERNAL,
POINTER, ALLOCATABLE, DIMENSION, VOLATILE, INTENT(INOUT), or INTENT(OUT)
attribute shall not be specified.
Thus: DIMENSION has been removed and just attr.codimension/attr.coarray_comp
are prohibited - as a dummy with assumed size as there copy-in/copy-out will
fail.