===================================================================
@@ -1880,8 +1880,7 @@ generate_finalization_wrapper (gfc_symbol *derived
for (fini = derived->f2k_derived->finalizers; fini; fini = fini->next)
{
- if (!fini->proc_tree)
- fini->proc_tree = gfc_find_sym_in_symtree (fini->proc_sym);
+ gcc_assert (fini->proc_tree); /* Should have been set in gfc_resolve_finalizers. */
if (fini->proc_tree->n.sym->attr.elemental)
{
fini_elem = fini;
===================================================================
@@ -12455,10 +12455,6 @@ resolve_fl_derived0 (gfc_symbol *sym)
/* Add derived type to the derived type list. */
add_dt_to_dt_list (sym);
- /* Check if the type is finalizable. This is done in order to ensure that the
- finalization wrapper is generated early enough. */
- gfc_is_finalizable (sym, NULL);
-
return true;
}