Hello,
Hope you guys having a good time. I have a question regarding the local pointer to a coarray data. Basically I have an array that I defined as below:
type coarrayElem2R
real, dimension(:,:), allocatable :: elemC2R
end type
type(coarrayElem2R) :: elem2RV[*]
allocate( elem2RV%elemC2R(local_start_point:local_start_point+local_N_elem2, e2r_idx_max), source = 0.0)
once I did some math on this allocated coarray paramter, I am trying to use pointer inside a subroutine to point to the coarray parameter (elem2RV%elemC2R). for that purpose I use the copointer but it returns an invalid character name for me. here is what I do:
real, copointer :: kc2caf(:)[*]
kc2 => elem2R(:,e2r_Temp(next_e2r_temparray))
and this is what compiler returns
Error: Invalid character in name at (1) runge_kutta.f08:222:7: kc2caf => elem2RV%elemC2R(:,e2r_Temp(next_e2r_temparray))
I would appreciate any recommendation or help that I fix my issue. The only thing for me is to point to the coarray parameter.
Best regards,
Ehsan