This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/54195] [4.8 Regression][OOP] IMPORT fails with GENERIC TBP: "is already present in the interface"


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

--- Comment #8 from janus at gcc dot gnu.org 2012-08-20 09:45:15 UTC ---
A similar test case (also a regression) was reported by Andrew Benson at
http://gcc.gnu.org/ml/fortran/2012-08/msg00101.html:


module gn

  implicit none

  type :: nc
   contains
     procedure :: assign => nca
     generic   :: assignment(=) => assign
  end type

  type, extends(nc) :: ncb
   contains
     procedure , nopass :: tis => bf
  end type

contains

  subroutine nca(to,from)
    class(nc), intent(out) :: to
    type(nc), intent(in) :: from
  end subroutine

  logical function bf()
    bf=.false.
  end function

end module



This fails with:

     generic   :: assignment(=) => assign
                                  1
Error: Entity 'nca' at (1) is already present in the interface


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]