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/68237] ICE on invalid with submodules


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

--- Comment #10 from Paul Thomas <pault at gcc dot gnu.org> ---
(In reply to Paul Thomas from comment #9)
> I'll take a look at Steve's proposed patch tonight. In the meantime, I have
> taken the PR.
> 
> Cheers
> 
> Paul

Steve's patch is good... obvious, even :-)

Here is a dejagnuified version of the testcase:

! { dg-do compile }
!
! Test the fix for PR68237 in which 'foo' caused a seg fault rather than an
error.
!
! Contributed by Martin Reinecke  <martin@mpa-garching.mpg.de>
!
module m1
  interface
    module subroutine bar
    end subroutine
  end interface
end module m1

submodule (m1) m2
contains
  module procedure foo ! { dg-error "must be in a generic module interface" }
  end procedure ! { dg-error "Expecting END SUBMODULE statement" }
end submodule

I'll try to find the time to commit this afternoon; otherwise it will be next
week.

Paul

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