------- Comment #2 from burnus at gcc dot gnu dot org  2010-07-27 08:29 -------
  subroutine foo(x)
     integer, allocatable :: x
  end subroutine

  integer, allocatable :: ptr
  call foo(ptr)
  end

Error: Dummy argument 'x' of procedure 'foo' at (1) has an attribute that
requires an explicit interface for this procedure

Expected: Could be more explicit, maybe.

 * * *

  subroutine foo(x)
     integer, allocatable :: x
  end subroutine

  interface
    subroutine foo(x)
       integer :: x
    end subroutine
  end interface
  integer, allocatable :: ptr
  call foo(ptr)
  end

Expected: Mismatched interface is detected.

 * * *

  subroutine foo(x)
     integer, allocatable :: x
  end subroutine

  interface
    subroutine foo(x)
       integer :: x
    end subroutine
  end interface
  integer :: ptr
  call foo(ptr)
  end

Expected: Mismatched actual argument is detected as well.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45086

Reply via email to