aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gfortran.dg/pr32238.f90
blob: 6af64ca606ad898468363ad6b25d83ba2a33dbbe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
!PR fortran/32238
! { dg-do compile }

module bug_test

contains
  subroutine bug(c)

  implicit none

  integer, parameter :: fp = selected_real_kind(13)
  complex(kind=fp)              :: c(:,:)
  where( abs( aimag( c ) ) < 1.e-10_fp )                             &
  &    c = cmplx( real( c , fp ) , 0._fp , fp )
  where( abs( real( c , fp ) ) < 1.e-10_fp )                         &
  &    c = cmplx( 0._fp , aimag( c ) , fp )

  return
  end subroutine bug

end module bug_test