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/16136] New: Conflicting attributes ALLOCATABLE, DUMMY


subroutine foo(x)
integer, allocatable :: x(:)
end

----------------------

integer, allocatable :: x(:)
                        1
Error: ALLOCATABLE attribute conflicts with DUMMY attribute at (1)

----------------------

Combining ALLOCATABLE and DUMMY attributes is okay, IMHO.

The Standard says (12.4.1.2, Actual arguments associated with
dummy data objects): "If a dummy argument is allocatable or a 
pointer, the associated actual argument shall be polymorphic 
[etc etc]".  

IBM xlf compiler accepts this, too.

-- 
           Summary: Conflicting attributes ALLOCATABLE, DUMMY
           Product: gcc
           Version: 3.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: lei at il dot ibm dot com
                CC: gcc-bugs at gcc dot gnu dot org


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


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