Heuristic: If the number of operands in the alias are more than the number of
[llvm/stm8.git] / test / FrontendFortran / 2009-02-09-FloorDivExpr.f90
blobddd05c549496bd08f1b0c98630204b0c6983026b
1 ! RUN: %llvmgcc -S %s
2 ! PR2437
3 program main
4 implicit none
5 call build (77)
6 contains
7 subroutine build (order)
8 integer :: order, i, j
11 call test (1, order, 3, (/ (i, i = 1, order, 3) /))
12 call test (order, 1, -3, (/ (i, i = order, 1, -3) /))
14 do j = -10, 10
15 call test (order + j, order, 5, (/ (i, i = order + j, order, 5) /))
16 call test (order + j, order, -5, (/ (i, i = order + j, order, -5) /))
17 end do
19 end subroutine build
21 subroutine test (from, to, step, values)
22 integer, dimension (:) :: values
23 integer :: from, to, step, last, i
25 last = 0
26 do i = from, to, step
27 last = last + 1
28 if (values (last) .ne. i) call abort
29 end do
30 if (size (values, dim = 1) .ne. last) call abort
31 end subroutine test
32 end program main