summaryrefslogtreecommitdiffstats
path: root/fortran/examples
diff options
context:
space:
mode:
authorScot Breitenfeld <brtnfld@hdfgroup.org>2012-12-12 04:30:22 (GMT)
committerScot Breitenfeld <brtnfld@hdfgroup.org>2012-12-12 04:30:22 (GMT)
commite92f4b1a7c2c0f4f41dc9a4102584e0dfa3988a3 (patch)
tree4ff6cc1234c1ad37fc599099d30f715cdeea6ed9 /fortran/examples
parent7155aa6f1dbf1d01765f5a61dbbeb13098f548f6 (diff)
downloadhdf5-e92f4b1a7c2c0f4f41dc9a4102584e0dfa3988a3.zip
hdf5-e92f4b1a7c2c0f4f41dc9a4102584e0dfa3988a3.tar.gz
hdf5-e92f4b1a7c2c0f4f41dc9a4102584e0dfa3988a3.tar.bz2
[svn-r23092] Cleaned-up printed output and corrected output comments
Tested: jam (gnu)
Diffstat (limited to 'fortran/examples')
-rw-r--r--fortran/examples/h5_extend.f904
-rw-r--r--fortran/examples/h5_subset.f9013
2 files changed, 8 insertions, 9 deletions
diff --git a/fortran/examples/h5_extend.f90 b/fortran/examples/h5_extend.f90
index 306d837..5f50b49 100644
--- a/fortran/examples/h5_extend.f90
+++ b/fortran/examples/h5_extend.f90
@@ -212,9 +212,9 @@ PROGRAM H5_EXTEND
CALL H5dread_f(dset_id, H5T_NATIVE_INTEGER, rdata, data_dims, &
error, memspace, dataspace)
- PRINT *,"Dataset:"
+ WRITE(*,'(A)') "Dataset:"
DO i = 1, dimsr(1)
- PRINT *, rdata(i,1:dimsr(2))
+ WRITE(*,'(100(I0,1X))') rdata(i,1:dimsr(2))
END DO
!
diff --git a/fortran/examples/h5_subset.f90 b/fortran/examples/h5_subset.f90
index 56c8ccc..6cb8f7a 100644
--- a/fortran/examples/h5_subset.f90
+++ b/fortran/examples/h5_subset.f90
@@ -107,11 +107,10 @@ PROGRAM H5_SUBSET
!
! Data Written to File
!
- PRINT*, "Original Data Written to File:"
+ WRITE(*,'(/,A)') "Original Data Written to File:"
DO i = 1, dim0
- PRINT*, DATA(i,1:dim1)
+ WRITE(*,'(100(1X,I0,1X))') DATA(i,1:dim1)
END DO
- PRINT*, " "
!
!
@@ -147,8 +146,8 @@ PROGRAM H5_SUBSET
!
CALL h5screate_simple_f(rank, dimsm, memspace, error)
- PRINT *,"Write subset to file specifying:"
- PRINT *, " offset=1x2 stride=1x1 count=3x4 block=1x1"
+ WRITE(*,'(/,A)') "Write subset to file specifying:"
+ WRITE(*,'(A,/)') " offset=2x1 stride=1x1 count=4x3 block=1x1"
!
! Write subset to dataset
@@ -163,9 +162,9 @@ PROGRAM H5_SUBSET
!
! Read entire dataset back
!
- PRINT *,"Data in File after Subset Written:"
+ WRITE(*,'(A)') "Data in File after Subset Written:"
DO i = 1, dim0
- PRINT *,rdata(i,1:dim1)
+ WRITE(*,'(100(1X,I0,1X))') rdata(i,1:dim1)
END DO
PRINT *, " "