OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [actual_array_vect_1.f90] - Blame information for rev 801

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do compile }
2
! PR fortran/32323
3
! Array sections with vector subscripts are not allowed
4
! with dummy arguments which have VOLATILE or INTENT OUT/INOUT
5
!
6
! Contributed by terry@chem.gu.se
7
!
8
module mod
9
implicit none
10
contains
11
subroutine aa(v)
12
integer,dimension(:),volatile::v
13
write(*,*)size(v)
14
v=0
15
end subroutine aa
16
subroutine bb(v)
17
integer,dimension(:),intent(out)::v
18
write(*,*)size(v)
19
v=0
20
end subroutine bb
21
end module mod
22
 
23
program ff
24
use mod
25
implicit none
26
integer,dimension(10)::w
27
w=1
28
call aa(w(2:4))
29
call aa(w((/3,2,1/))) ! { dg-error "vector subscript" }
30
call bb(w(2:4))
31
call bb(w((/3,2,1/))) ! { dg-error "vector subscript" }
32
write(*,*)w
33
end
34
 
35
! { dg-final { cleanup-modules "mod" } }

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.