summaryrefslogtreecommitdiffstats
path: root/fortran
diff options
context:
space:
mode:
authorElena Pourmal <epourmal@hdfgroup.org>2000-11-17 14:46:05 (GMT)
committerElena Pourmal <epourmal@hdfgroup.org>2000-11-17 14:46:05 (GMT)
commit0d4da25d8610f69812ce0042c5e4a8cfae805e0f (patch)
treefa343d25c4b6a2f91d53fb7c0b869052f9448792 /fortran
parent81f5bf419d32e3b596b2e6b0f1bf131b0d930878 (diff)
downloadhdf5-0d4da25d8610f69812ce0042c5e4a8cfae805e0f.zip
hdf5-0d4da25d8610f69812ce0042c5e4a8cfae805e0f.tar.gz
hdf5-0d4da25d8610f69812ce0042c5e4a8cfae805e0f.tar.bz2
[svn-r2964]
Purpose: Code maintenance Description: Fixed the code to use new h5tarray_create_f subroutine to create a compound datatype with an array field. Platforms tested: Solaris 2.6
Diffstat (limited to 'fortran')
-rw-r--r--fortran/test/tH5T.f9011
1 files changed, 8 insertions, 3 deletions
diff --git a/fortran/test/tH5T.f90 b/fortran/test/tH5T.f90
index ca2f4ab..66c4223 100644
--- a/fortran/test/tH5T.f90
+++ b/fortran/test/tH5T.f90
@@ -30,6 +30,7 @@
INTEGER(HID_T) :: dspace_id ! Dataspace identifier
INTEGER(HID_T) :: dtype_id ! Compound datatype identifier
INTEGER(HID_T) :: dtarray_id ! Compound datatype identifier
+ INTEGER(HID_T) :: arrayt_id ! Array datatype identifier
INTEGER(HID_T) :: dt1_id ! Memory datatype identifier (for character field)
INTEGER(HID_T) :: dt2_id ! Memory datatype identifier (for integer field)
INTEGER(HID_T) :: dt3_id ! Memory datatype identifier (for double precision field)
@@ -238,12 +239,16 @@
CALL check("h5tcreate_f", error, total_error)
offset = 0
CALL h5tinsert_f(dtarray_id, "char_field", offset, H5T_NATIVE_CHARACTER, error)
+ CALL check("h5tinsert_f", error, total_error)
offset = type_sizec
- CALL h5tinsert_array_f(dtarray_id, "array_filed", offset, size(array_dims), &
- array_dims, H5T_NATIVE_REAL, error)
- CALL check("h5tinsert_array_f", error, total_error)
+ CALL h5tarray_create_f(H5T_NATIVE_REAL, size(array_dims), array_dims, arrayt_id, error)
+ CALL check("h5tarray_create_f", error, total_error)
+ CALL h5tinsert_f(dtarray_id,"array_field", offset, arrayt_id, error)
+ CALL check("h5tinsert_f", error, total_error)
CALL h5tcommit_f(file_id, "Compound_with_array_member", dtarray_id, error)
CALL check("h5tcommit_f", error, total_error)
+ CALL h5tclose_f(arrayt_id, error)
+ CALL check("h5tclose_f", error, total_error)
CALL h5tclose_f(dtarray_id, error)
CALL check("h5tclose_f", error, total_error)