annotate gcc/testsuite/gfortran.dg/intent_out_1.f90 @ 132:d34655255c78

update gcc-8.2
author mir3636
date Thu, 25 Oct 2018 10:21:07 +0900
parents 04ced10e8804
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 ! { dg-do compile }
kono
parents:
diff changeset
2 ! Tests the fix for PRs 18578, 18579 and their repeats 20857 and 20885.
kono
parents:
diff changeset
3 ! Contributed by Paul Thomas <pault@gcc@gnu.org>
kono
parents:
diff changeset
4 real, parameter :: a =42.0
kono
parents:
diff changeset
5 real :: b
kono
parents:
diff changeset
6 call foo(b + 2.0) ! { dg-error "variable definition context" }
kono
parents:
diff changeset
7 call foo(a) ! { dg-error "variable definition context" }
kono
parents:
diff changeset
8 call bar(b + 2.0) ! { dg-error "variable definition context" }
kono
parents:
diff changeset
9 call bar(a) ! { dg-error "variable definition context" }
kono
parents:
diff changeset
10 contains
kono
parents:
diff changeset
11 subroutine foo(a)
kono
parents:
diff changeset
12 real, intent(out) :: a
kono
parents:
diff changeset
13 a = 0.0
kono
parents:
diff changeset
14 end subroutine foo
kono
parents:
diff changeset
15 subroutine bar(a)
kono
parents:
diff changeset
16 real, intent(INout) :: a
kono
parents:
diff changeset
17 a = 0.0
kono
parents:
diff changeset
18 end subroutine bar
kono
parents:
diff changeset
19 end