This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/47240] [F03] segfault with procedure pointer component
- From: "burnus at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 12 Jan 2011 21:49:30 +0000
- Subject: [Bug fortran/47240] [F03] segfault with procedure pointer component
- Auto-submitted: auto-generated
- References: <bug-47240-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47240
--- Comment #11 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-01-12 21:49:23 UTC ---
(In reply to comment #9)
> > pr35971_red.f90:67:0: internal compiler error: verify_stmts failed
I can reproduce this with a clean trunk on x86-64-linux with both -m32 and
-m64.
> I can not reproduce this at r168655 (plus patch from comment #7)
How do you configure gfortran? (I did a full bootstrap and did *not* use
--enable-checking=release.)
* * *
Regarding the test case: I think it is invalid:
function aux(x)
interface
subroutine x() bind(C)
end subroutine x
end interface
but you pass as actual argument the function (!) "make_mess" which take also
arguments to "aux". (In get_funloc everything is still fine - the actual
argument has the proper type: "abstract_fun".)
I believe that the argument mismatch is invalid. And the compiler has no chance
to detect this at (front-end) compile time as you use a dummy "external y"
instead of the explicit interface of "aux".
Like always: A compiler can tolerate to a certain extend argument mismatches -
but especially with higher optimization values, it trusts the user that (s)he
knows what he is doing - and that (s)he stays within what the standard allows.
(The same is true for alias analysis.)