Changeset View
Changeset View
Standalone View
Standalone View
flang/test/Semantics/resolve55.f90
Show All 30 Lines | |||||
subroutine s4(arg) | subroutine s4(arg) | ||||
! Cannot have a dummy INTENT(IN) in a locality spec | ! Cannot have a dummy INTENT(IN) in a locality spec | ||||
real, intent(in) :: arg | real, intent(in) :: arg | ||||
!ERROR: INTENT IN argument 'arg' not allowed in a locality-spec | !ERROR: INTENT IN argument 'arg' not allowed in a locality-spec | ||||
do concurrent(i=1:5) local(arg) | do concurrent(i=1:5) local(arg) | ||||
end do | end do | ||||
end subroutine s4 | end subroutine s4 | ||||
subroutine s5() | module m | ||||
! Cannot have a variable of a finalizable type in a locality spec | ! Cannot have a variable of a finalizable type in a locality spec | ||||
type t1 | type t1 | ||||
integer :: i | integer :: i | ||||
contains | contains | ||||
final :: f | final :: f | ||||
end type t1 | end type t1 | ||||
contains | |||||
subroutine s5() | |||||
type(t1) :: var | type(t1) :: var | ||||
!ERROR: Finalizable variable 'var' not allowed in a locality-spec | !ERROR: Finalizable variable 'var' not allowed in a locality-spec | ||||
do concurrent(i=1:5) local(var) | do concurrent(i=1:5) local(var) | ||||
end do | end do | ||||
end subroutine s5 | |||||
contains | |||||
subroutine f(x) | subroutine f(x) | ||||
type(t1) :: x | type(t1) :: x | ||||
end subroutine f | end subroutine f | ||||
end subroutine s5 | end module m | ||||
subroutine s6 | subroutine s6 | ||||
! Cannot have a nonpointer polymorphic dummy argument in a locality spec | ! Cannot have a nonpointer polymorphic dummy argument in a locality spec | ||||
type :: t | type :: t | ||||
integer :: field | integer :: field | ||||
end type t | end type t | ||||
contains | contains | ||||
subroutine s(x, y) | subroutine s(x, y) | ||||
Show All 29 Lines |