aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gfortran.dg/associate_17.f90
blob: 5c39cf06247a6c71b9b166b94d79d1a938ceee5e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
! { dg-do run }
! Test the fix for PR61406
! Contributed by Adam Hirst  <adam@aphirst.karoo.co.uk>
program test
  implicit none
  real :: theta = 1.0

  associate (n => [cos(theta), sin(theta)])
    if (abs (norm2(n) - 1.0) .gt. 1.0e-4) call abort
  end associate

end program test