This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/63529] Bad error and ICE with Cray Pointers in Modules


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

kargl at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |kargl at gcc dot gnu.org

--- Comment #13 from kargl at gcc dot gnu.org ---
I intend to close this PR after updating the information
about Cray pointers and an assumed-sized array.  The
Fortran clearly states


8.5.8.5 Assumed-size array
An assumed-size array is a dummy argument array whose size
is assumed from that of its effective argument, ...

An assumed-sized simply cannot appear in the specification
portion of a module. The text in gfortran.info will be


    The pointer is an integer that is intended to hold
    a memory address. The pointee may be an array or scalar.
    If an assumed-size array is permitted within the scoping
    unit, a pointee can be an assumed-size array. That is, the
    last dimension may be left unspecified by using a * in place
    of a value. A pointee cannot be an assumed shape array. No
    space is allocated for the pointee.

Index: gfortran.texi
===================================================================
--- gfortran.texi       (revision 258468)
+++ gfortran.texi       (working copy)
@@ -1906,10 +1906,13 @@ or,
         pointer ( <pointer1> , <pointee1> ), ( <pointer2> , <pointee2> ), ...
 @end smallexample
 The pointer is an integer that is intended to hold a memory address.
-The pointee may be an array or scalar.  A pointee can be an assumed
-size array---that is, the last dimension may be left unspecified by
-using a @code{*} in place of a value---but a pointee cannot be an
-assumed shape array.  No space is allocated for the pointee.
+The pointee may be an array or scalar.
+If an assumed-size array is permitted within the scoping unit, a
+pointee can be an assumed-size array.
+That is, the last dimension may be left unspecified by using a @code{*}
+in place of a value.
+A pointee cannot be an assumed shape array.
+No space is allocated for the pointee.

 The pointee may have its type declared before or after the pointer
 statement, and its array specification (if any) may be declared

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]