This is the mail archive of the
mailing list for the GCC project.
Re: [Patch, fortran] PR64932 [4.9/5 Regression] ICE in gfc_conv_descriptor_data_get for generated finalizer
- From: Tobias Burnus <tobias dot burnus at physik dot fu-berlin dot de>
- To: Paul Richard Thomas <paul dot richard dot thomas at gmail dot com>, gcc-patches at gcc dot gnu dot org, fortran at gcc dot gnu dot org
- Date: Wed, 11 Feb 2015 12:00:20 +0100
- Subject: Re: [Patch, fortran] PR64932 [4.9/5 Regression] ICE in gfc_conv_descriptor_data_get for generated finalizer
- Authentication-results: sourceware.org; auth=none
Dear Paul, dear all,
first, sorry for the belate review.
Paul Thomas wrote:
> This is a slight development of the patch posted on the PR itself.
> class.c(finalize_component) is not able to deal correctly with
> non-allocatable, derived type array components that have allocatable
> components. Rather than generating loops in finalize_component, the
> condition is detected in trans-stmt.c(gfc_trans_deallocate) and
> gfc_deallocate_alloc_comp is called after obtaining the derived type
> for the array and checking that it is not finalizable.
> Happily, this fix does not generate the error:
> Error: Two or more part references with nonzero rank must not be
> specified at (1)
> which occurs if the code is written explicitly.
> Bootstraps and regtests on FC21/x86_64
> OK for trunk and 4.9?
OK. I think the patch should be okay - even if the code is not really
beautiful. (Fault of our data representation not of the patch itself.)