------- Comment #1 from dfranke at gcc dot gnu dot org  2008-04-05 22:57 -------
F95, section 12.6 "Pure procedures":

Constraint:   In a pure subprogram any variable which is in common or accessed
by host or use association, is a dummy argument to a pure function, is a dummy
argument with INTENT (IN) to a pure subroutine, or an object that is storage
associated with any such variable, shall not be used in the following contexts:
     (1)    As the variable of an assignment-stmt;
     (2)    As a DO variable or implied DO variable;
     (3)    As an input-item in a read-stmt from an internal file;
     (4)    As an internal-file-unit in a write-stmt;
     (5)    As an IOSTAT= specifier in an input or output statement with
an
            internal file;
     (6)    As the pointer-object of a pointer-assignment-stmt;
     (7)    As the target of a pointer-assignment-stmt;
     (8)    As the expr of an assignment-stmt in which the variable is of a
            derived type if the derived type has a pointer component at any
            level of component selection;
     (9)    As an allocate-object or stat-variable in an allocate-stmt or
            deallocate-stmt, or as a pointer-object in a nullify-stmt; or
    (10)    As an actual argument associated with a dummy argument with INTENT
            (OUT) or INTENT (INOUT) or with the POINTER attribute.

Thus, the case shown above should be valid.


-- 

dfranke at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dfranke at gcc dot gnu dot
                   |                            |org
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2008-04-05 22:57:37
               date|                            |


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

Reply via email to