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/61767] ICE in generate_finalization_wrapper at fortran/class.c:1491


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61767

--- Comment #2 from reubendb at gmail dot com ---
I don't know why this is the case, but adding an allocatable variable in the
type definition of MessageTemplate above avoids the ICE, i.e the following does
not produce ICE:

module Message_Template
  use Communicator_Form
  implicit none
  private
  type, public, abstract :: MessageTemplate
    integer, allocatable :: &
      Dummy
    type ( CommunicatorForm ), pointer :: &
      Communicator => null ( )
  end type MessageTemplate
contains
  subroutine InitializeTemplate ( M )
    class ( MessageTemplate ), intent ( inout ), target :: &
      M
  end subroutine InitializeTemplate
end module Message_Template

Note the slight addition of "Dummy" variable above.


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