summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/pr47757-1.f90
blob: 1c40f987400afcd03aacebc1fe331cc37d98801f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
! PR libfortran/47757
! { dg-do run }

  integer(1) :: a1(2,2)
  integer(2) :: a2(2,2)
  integer(4) :: a4(2,2)
  integer(8) :: a8(2,2)
  logical :: mask(2,2)
  logical :: mask2
  a1 = 0
  a2 = 0
  a3 = 0
  a4 = 0
  mask2 = .true.
  mask = reshape([.true.,.true.,.false.,.true.],[2,2])
  print *, iany(a1, dim=1, mask=mask)
  print *, iany(a2, dim=1, mask=mask)
  print *, iany(a4, dim=1, mask=mask)
  print *, iany(a8, dim=1, mask=mask)
  print *, iall(a1, dim=1, mask=mask)
  print *, iall(a2, dim=1, mask=mask)
  print *, iall(a4, dim=1, mask=mask)
  print *, iall(a8, dim=1, mask=mask)
  print *, iparity(a1, dim=1, mask=mask)
  print *, iparity(a2, dim=1, mask=mask)
  print *, iparity(a4, dim=1, mask=mask)
  print *, iparity(a8, dim=1, mask=mask)
  print *, iany(a1, dim=1, mask=mask2)
  print *, iany(a2, dim=1, mask=mask2)
  print *, iany(a4, dim=1, mask=mask2)
  print *, iany(a8, dim=1, mask=mask2)
  print *, iall(a1, dim=1, mask=mask2)
  print *, iall(a2, dim=1, mask=mask2)
  print *, iall(a4, dim=1, mask=mask2)
  print *, iall(a8, dim=1, mask=mask2)
  print *, iparity(a1, dim=1, mask=mask2)
  print *, iparity(a2, dim=1, mask=mask2)
  print *, iparity(a4, dim=1, mask=mask2)
  print *, iparity(a8, dim=1, mask=mask2)
end