2017-04-21 Janus Weil <janus@gcc.gnu.org>
Backport from trunk
PR fortran/80361
* class.c (generate_finalization_wrapper): Give the finalization wrapper
the recursive attribute.
2017-04-21 Janus Weil <janus@gcc.gnu.org>
Backport from trunk
PR fortran/80361
* gfortran.dg/class_62.f90: New test case.
From-SVN: r247071
+2017-04-21 Janus Weil <janus@gcc.gnu.org>
+
+ Backport from trunk
+ PR fortran/80361
+ * class.c (generate_finalization_wrapper): Give the finalization wrapper
+ the recursive attribute.
+
2017-04-14 Dominique d'Humieres <dominiq@lps.ens.fr>
Backport from trunk
final->attr.flavor = FL_PROCEDURE;
final->attr.function = 1;
final->attr.pure = 0;
+ final->attr.recursive = 1;
final->result = final;
final->ts.type = BT_INTEGER;
final->ts.kind = 4;
+2017-04-21 Janus Weil <janus@gcc.gnu.org>
+
+ Backport from trunk
+ PR fortran/80361
+ * gfortran.dg/class_62.f90: New test case.
+
2017-04-21 Christophe Lyon <christophe.lyon@linaro.org>
Backport from mainline
--- /dev/null
+! { dg-do run }
+! { dg-options "-fcheck=recursion" }
+!
+! PR 80361: [5/6/7 Regression] bogus recursive call to nonrecursive procedure with -fcheck=recursion
+!
+! Contributed by Jürgen Reuter <juergen.reuter@desy.de>
+
+program main_ut
+
+ implicit none
+
+ type :: prt_spec_expr_t
+ end type
+
+ type :: prt_expr_t
+ class(prt_spec_expr_t), allocatable :: x
+ end type
+
+ type, extends (prt_spec_expr_t) :: prt_spec_list_t
+ type(prt_expr_t) :: e
+ end type
+
+ class(prt_spec_list_t), allocatable :: y
+
+ allocate (y)
+ allocate (prt_spec_list_t :: y%e%x)
+ deallocate(y)
+
+end program