title: Why is the KIND parameter not recognized inside an abstract interface?
body: <p>I may be missing something quite obvious since i'm just starting with fortran, but somehow the parameter for the real_kind is out of scope inside the abstract interface.</p>
  <pre><code>program test
  
      implicit none
  
      integer, parameter :: Mydp = selected_real_kind(15, 307)
  
      abstract interface
        function Myinterface(C)
           real(Mydp) :: Myinterface
           real(Mydp), intent (in) :: C
        end function Myinterface
      end interface
  
      procedure (Myinterface), pointer :: myfunc =&gt; null()
  
      myfunc =&gt; test2
  
      call usefunc(myfunc,3.0_Mydp)
  
      contains
  
      function test2(a)
          real(Mydp), intent(in) :: a
          real(Mydp)                :: test2
          test2 = a*a
      end function
  
  
      subroutine usefunc(myfunc,a)
          real(Mydp), intent(in) :: a
          procedure (Myinterface), pointer :: myfunc
  
          print *,myfunc(a)
  
      end subroutine
  
  
  end program
  </code></pre>
  <p>This does compile and run quite fine if I remove all references to Mydp.
  What should I change?</p>