https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84189
Bug ID: 84189
Summary: Internal procedure allowed as type bound procedure
Product: gcc
Version: 8.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
Assignee: unassigned at gcc dot gnu.org
Reporter: neil.n.carlson at gmail dot com
Target Milestone: ---
C465 (F08) prohibits an internal procedure from being a type bound procedure,
but gfortran mistakenly allows it when the TPB has the NOPASS attribute.
The following invalid example should fail to compile, but gfortran compiles it
without error.
module foobar
type :: foo
contains
procedure, nopass :: bar
end type
contains
subroutine bar
end subroutine
end module
Note that the func_result_6.f90 testsuite problem, and perhaps others, use this
type of invalid code.