h5dwrite_f problem (Error: There is no specific subroutine for the generic 'h5dwrite_f' at (1))

Hi Ekin,
Looking at the source code for HDF5 1.8.5p1, h5dwrite_f is implemented
using overloading. h5dwrite_f appears to be a generic name for a number of
module procedures. Which procedure gets called depends on the argument
signature of the call to h5dwrite_f. It would appear the actual argument,
f_ptr is the source of your trouble as its type is c_ptr and the
compiler/linker can't match the generic, overloaded procedure to a specific
procedure because there are none with a third argument of TYPE(c_ptr). If
you need to use a C pointer, I would recomend calling the C API (and
possibly migrate this module to C), as it would appear that the Fortran API
for writing compound data sets is more awkward than the C API. At
http://www.hdfgroup.org/HDF5/doc/UG/UG_frame11Datatypes.html in
"Creating and Writing Datasets with Compound Datatypes" it says:

The example below contains a Fortran example that creates and writes a

dataset with a compound datatype. As this example illustrates, writing and
reading compound datatypes in Fortran is *always* done by fields. The
content of the written file is the same as shown in the example above.

It might be worthwhile looking at this example.

I hope this helps,
Izaak Beekman


Princeton University Doctoral Candidate
Mechanical and Aerospace Engineering

UMD-CP Visiting Graduate Student
Aerospace Engineering

On Fri, Mar 2, 2012 at 9:49 AM, <hdf-forum-request@hdfgroup.org> wrote:

h5dwrite_f problem (Error: There is no specific subroutine for the generic
'h5dwrite_f' at (1))