This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/78466] New: [coarray] Explicit cobounds of a procedures parameter not respected
- From: "vehre at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 22 Nov 2016 10:37:51 +0000
- Subject: [Bug fortran/78466] New: [coarray] Explicit cobounds of a procedures parameter not respected
- Auto-submitted: auto-generated
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78466
Bug ID: 78466
Summary: [coarray] Explicit cobounds of a procedures parameter
not respected
Product: gcc
Version: 7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
Assignee: unassigned at gcc dot gnu.org
Reporter: vehre at gcc dot gnu.org
Target Milestone: ---
The testcase in gcc/testsuite/gfortran.dg/poly_run_2.f90 gives explicit
cobounds for the argument A to procedure s(). Those are not taken into account,
at least not in the way given (excerpt):
type t
end type t
class(t), allocatable :: A[:,:]
allocate (A[1:4,-5:*])
call s(A)
contains
subroutine s(x)
class(t) :: x[4,2:*]
if (any (lcobound(x) /= [1, 2])) call abort ()
if (num_images() == 1) then
if (any (ucobound(x) /= [4, 2])) call abort () ! Fails
else
if (ucobound(x,dim=1) /= 4) call abort ()
end if
end subroutine s
end
Note: The testcase in general is made non-functional by the if(allocated(A))
stop as second line, as it is living in trunk upto r242691.