[J3] Custom Memory Allocator

Vipul Parekh parekhvs at gmail.com
Fri Nov 15 15:47:11 EST 2019


Reuben,

Fortran standard states the object "shall have been allocated using
the same mechanism as the Fortran ALLOCATE statement" for use with
enhanced interoperability features introduced in Fortran 2018 i.e., in
order to work with CFI_* functions and C descriptors.

But with custom allocator, you can never know if you have the same
mechanism as Fortran ALLOCATE statement.  Thus the C descriptor based
approach is effectively not an option.

So you're then back to the "opaque pointer" option introduced starting
Fortran 2003.  Now, would there be a reason for you not to consider
this which then made you send this inquiry?

Regards,
Vipul Parekh


More information about the J3 mailing list