[Bug fortran/58023] [F03] ICE on invalid with bad PPC declaration
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58023 --- Comment #8 from janus at gcc dot gnu.org --- Author: janus Date: Thu Jan 15 18:28:02 2015 New Revision: 219676 URL: https://gcc.gnu.org/viewcvs?rev=219676root=gccview=rev Log: 2015-01-15 Janus Weil ja...@gcc.gnu.org PR fortran/58023 * resolve.c (resolve_fl_derived0): Continue resolving next component after error. 2015-01-15 Janus Weil ja...@gcc.gnu.org PR fortran/58023 * gfortran.dg/proc_ptr_comp_43.f90: New. Added: trunk/gcc/testsuite/gfortran.dg/proc_ptr_comp_43.f90 Modified: trunk/gcc/fortran/ChangeLog trunk/gcc/fortran/resolve.c trunk/gcc/testsuite/ChangeLog
[Bug fortran/58023] [F03] ICE on invalid with bad PPC declaration
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58023 janus at gcc dot gnu.org changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|--- |FIXED --- Comment #9 from janus at gcc dot gnu.org --- r219676 fixes the remaining problem with comment 0. Closing.
[Bug fortran/58023] [F03] ICE on invalid with bad PPC declaration
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58023 --- Comment #6 from janus at gcc dot gnu.org --- Author: janus Date: Sun Jan 11 19:13:24 2015 New Revision: 219439 URL: https://gcc.gnu.org/viewcvs?rev=219439root=gccview=rev Log: 2015-01-11 Janus Weil ja...@gcc.gnu.org PR fortran/58023 * resolve.c (resolve_fl_derived0): Set error flag if problems with the interface of a procedure-pointer component were detected. 2015-01-11 Janus Weil ja...@gcc.gnu.org PR fortran/58023 * gfortran.dg/proc_ptr_comp_42.f90: New. Added: trunk/gcc/testsuite/gfortran.dg/proc_ptr_comp_42.f90 Modified: trunk/gcc/fortran/ChangeLog trunk/gcc/fortran/resolve.c trunk/gcc/testsuite/ChangeLog
[Bug fortran/58023] [F03] ICE on invalid with bad PPC declaration
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58023 --- Comment #7 from janus at gcc dot gnu.org --- I have finally committed the patch in comment 2 (sorry that it took so long). The ICE on comment 0 is still there, but for consistency one should do a bit more than shown in comment 5. Will take care of that next.
[Bug fortran/58023] [F03] ICE on invalid with bad PPC declaration
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58023 janus at gcc dot gnu.org changed: What|Removed |Added Keywords||ice-on-invalid-code Status|UNCONFIRMED |NEW Last reconfirmed||2013-07-30 CC||janus at gcc dot gnu.org Summary|ICE on invalid with missing |[F03] ICE on invalid with |NOPASS |bad PPC declaration Ever confirmed|0 |1 --- Comment #1 from janus at gcc dot gnu.org --- Confirmed. The same ICE occurs on this variant: implicit none type :: sfd procedure(mr), pointer :: mr2 end type type(sfd):: d print *, d%mr2() end
[Bug fortran/58023] [F03] ICE on invalid with bad PPC declaration
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58023 janus at gcc dot gnu.org changed: What|Removed |Added Status|NEW |ASSIGNED Assignee|unassigned at gcc dot gnu.org |janus at gcc dot gnu.org --- Comment #2 from janus at gcc dot gnu.org --- Draft patch: Index: gcc/fortran/resolve.c === --- gcc/fortran/resolve.c(revision 201283) +++ gcc/fortran/resolve.c(working copy) @@ -12043,9 +12043,11 @@ resolve_fl_derived0 (gfc_symbol *sym) { gfc_symbol *ifc = c-ts.interface; - if (!sym-attr.vtype - !check_proc_interface (ifc, c-loc)) -return false; + if (!sym-attr.vtype !check_proc_interface (ifc, c-loc)) +{ + c-tb-error = 1; + return false; +} if (ifc-attr.if_source || ifc-attr.intrinsic) {
[Bug fortran/58023] [F03] ICE on invalid with bad PPC declaration
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58023 --- Comment #3 from janus at gcc dot gnu.org --- (In reply to janus from comment #2) Draft patch: Regtests cleanly. Will commit as obvious.
[Bug fortran/58023] [F03] ICE on invalid with bad PPC declaration
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58023 --- Comment #4 from janus at gcc dot gnu.org --- (In reply to janus from comment #2) Draft patch: Unfortunately, this patch only fixes comment 1, but not comment 0!
[Bug fortran/58023] [F03] ICE on invalid with bad PPC declaration
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58023 --- Comment #5 from janus at gcc dot gnu.org --- Comment 0 can be fixed by the following additional hunk in resolve.c: @@ -12148,7 +12147,7 @@ resolve_fl_derived0 (gfc_symbol *sym) must have at least one argument, c-name, c-loc); c-tb-error = 1; - return false; + continue; } me_arg = c-ts.interface-formal-sym; }