PR tree-optimization/86415 - strlen() not folded for substrings within constant arrays
[official-gcc.git] / gcc / testsuite / gfortran.dg / elemental_args_check_7.f90
blob7b5843b950b933179dda28f4725fa3b159e67ccc
1 ! { dg-do compile }
3 ! PR fortran/55638
5 ! Additionally, VALUE no INTENT is required (and only "intent(in)" allowed)
8 elemental subroutine foo(x, y, z)
9 integer, intent(inout) :: x
10 integer, VALUE :: y
11 integer, VALUE, intent(in) :: z
12 x = y
13 end subroutine foo
15 impure elemental subroutine foo2(x, y, z) ! { dg-error "Argument 'x' of elemental procedure 'foo2' at .1. must have its INTENT specified or have the VALUE attribute" }
16 integer :: x
17 integer, VALUE :: y
18 integer, VALUE :: z
19 x = y
20 end subroutine foo2
22 subroutine foo3(x, y, z)
23 integer, VALUE, intent(in) :: x
24 integer, VALUE, intent(inout) :: y ! { dg-error "VALUE attribute conflicts with INTENT.INOUT. attribute" }
25 integer, VALUE, intent(out) :: z ! { dg-error "VALUE attribute conflicts with INTENT.OUT. attribute" }
26 end subroutine foo3