Debian Codegraph @

gcc/testsuite/gfortran.dg/pointer_intent_6.f90

raw
1 ! { dg-do compile }
2 !
3 ! PR fortran/52864
4 !
5 ! Assigning to an intent(in) pointer (which is valid).
6 !
7 program test
8 type PoisFFT_Solver3D
9 complex, dimension(:,:,:), &
10 pointer :: work => null()
11 end type PoisFFT_Solver3D
12 contains
13 subroutine PoisFFT_Solver3D_FullPeriodic(D, p)
14 type(PoisFFT_Solver3D), intent(in) :: D
15 real, intent(in), pointer :: p(:)
16 D%work(i,j,k) = 0.0
17 p = 0.0
18 end subroutine
19 end