summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/pr35944-1.f90
blob: 76521cad9e9e72c1d876f002885af02266fc75d2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
! { dg-do run }

  implicit none
  integer i
  real rda1(10), rda(10), rval
  double precision dda1(10), dda(10), dval

  rda = (/ 1,2,3,4,5,6,7,8,9,10 /)
  rDA1 = MOD (1.1*(rDA(1)-5.0), P=(rDA-2.5))
  DO i = 1, 10
    rVAL = MOD (1.1*(rDA(1)-5.0), P=(rDA(i)-2.5))
    if (rval /= rda1(i)) call abort
  enddo

  dda = (/ 1,2,3,4,5,6,7,8,9,10 /)
  dDA1 = MOD (1.1d0*(dDA(1)-5.0d0), P=(dDA-2.5d0))
  DO i = 1, 10
    dVAL = MOD (1.1d0*(dDA(1)-5.0d0), P=(dDA(i)-2.5d0))
    if (dval /= dda1(i)) call abort
  enddo

end