Commit f477062c by Thomas Koenig

re PR fortran/92764 (ICE in gfc_procedure_use)

2018-12-08  Thomas Koenig  <tkoenig@gcc.gnu.org>

    PR fortran/92764
    * interface.c (gfc_procedure_use): Check for existence of derived
    component before using (twice).

2018-12-08  Thomas Koenig  <tkoenig@gcc.gnu.org>

    PR fortran/92764
    * gfortran.dg/interface_44.f90: New test.

From-SVN: r279087
parent c9942e5f
2018-12-08 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/92764
* interface.c (gfc_procedure_use): Check for existence of derived
component before using (twice).
2019-12-08 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/92755
......
......@@ -3888,6 +3888,7 @@ gfc_procedure_use (gfc_symbol *sym, gfc_actual_arglist **ap, locus *where)
/* F2008, C1303 and C1304. */
if (a->expr
&& (a->expr->ts.type == BT_DERIVED || a->expr->ts.type == BT_CLASS)
&& a->expr->ts.u.derived
&& ((a->expr->ts.u.derived->from_intmod == INTMOD_ISO_FORTRAN_ENV
&& a->expr->ts.u.derived->intmod_sym_id == ISOFORTRAN_LOCK_TYPE)
|| gfc_expr_attr (a->expr).lock_comp))
......@@ -3901,6 +3902,7 @@ gfc_procedure_use (gfc_symbol *sym, gfc_actual_arglist **ap, locus *where)
if (a->expr
&& (a->expr->ts.type == BT_DERIVED || a->expr->ts.type == BT_CLASS)
&& a->expr->ts.u.derived
&& ((a->expr->ts.u.derived->from_intmod == INTMOD_ISO_FORTRAN_ENV
&& a->expr->ts.u.derived->intmod_sym_id
== ISOFORTRAN_EVENT_TYPE)
......
2018-12-08 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/92764
* gfortran.dg/interface_44.f90: New test.
2019-12-08 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/92755
......
! { dg-do compile }
! PR 92964 - this used to ICE.
! Original test case by Arseny Solokha
type(e6) function dn() ! { dg-error "The type for function" }
call sub(dn)
end function dn
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment