On Fri, Mar 3, 2023 at 10:14 PM Jerry D via Fortran wrote:
> I am certainly not a C++ expert but it seems to me this all begs for
> automatic finalization where one would not have to invoke free at all.
> I suspect the gfortran frontend is not designed for such things.
+1 for RAII
This is about OpenMP's "deep mapping" of allocatable components of derived
types.
The basic feature is on OG12 (and OG11) but yet in GCC mainline. The old
submissions are at
https://gcc.gnu.org/pipermail/gcc-patches/2022-April/593704.html
My plan is to get the whole feature into GCC 14 once tr
On OG12, the OpenMP deep-mapping support added a callback procedure to the
vtable.
That one did not handle error recovery well (ICE when a CLASS component as not
(class_)ok.
The attached patch has been committed as
https://gcc.gnu.org/g:9c18db65914a751e4a1d9330ccc1659fe5ef270d
and applies only
[GCC 13 vs GCC 14]
I am unsure whether this should still go to GCC 13 or not. It is somewhat larger
albeit well contained (Fortran, only OpenMP, ...) and fixes real-world bugs,
but it is not a regression - and we are meanwhile slowly approaching the
release.
An alternative would be to go to GCC