[svn-r20349] BZ1725: H5DUMP displays type of reference for H5T_REFERENCE

Tested: local linux
This commit is contained in:
Allen Byrne 2011-03-25 16:19:25 -05:00
parent 378dc5ec28
commit 8656f3a9a5
4 changed files with 14 additions and 18 deletions

View File

@ -1198,16 +1198,12 @@ print_datatype(hid_t type,unsigned in_group)
case H5T_REFERENCE:
printf("H5T_REFERENCE");
/* The BNF document states that the type of reference should be
* displayed after "H5T_REFERENCE". Therefore add the missing
* reference type if the region command line option is used. This
* reference type will not be displayed if the region option is not used. */
if(display_region) {
if (H5Tequal(type, H5T_STD_REF_DSETREG)==TRUE) {
printf(" { H5T_STD_REF_DSETREG }");
}
else {
printf(" { H5T_STD_REF_OBJECT }");
}
* displayed after "H5T_REFERENCE". */
if (H5Tequal(type, H5T_STD_REF_DSETREG)==TRUE) {
printf(" { H5T_STD_REF_DSETREG }");
}
else {
printf(" { H5T_STD_REF_OBJECT }");
}
break;

View File

@ -9,7 +9,7 @@ GROUP "/" {
DATA {
}
ATTRIBUTE "Attribute1" {
DATATYPE H5T_REFERENCE
DATATYPE H5T_REFERENCE { H5T_STD_REF_DSETREG }
DATASPACE SIMPLE { ( 4 ) / ( 4 ) }
DATA {
(0): DATASET /Dataset2 {(2,2)-(7,7)}, DATASET /Dataset2 {(6,9),

View File

@ -4,7 +4,7 @@ Expected output for 'h5dump tdatareg.h5'
HDF5 "tdatareg.h5" {
GROUP "/" {
DATASET "Dataset1" {
DATATYPE H5T_REFERENCE
DATATYPE H5T_REFERENCE { H5T_STD_REF_DSETREG }
DATASPACE SIMPLE { ( 4 ) / ( 4 ) }
DATA {
DATASET /Dataset2 {(2,2)-(7,7)}, DATASET /Dataset2 {(6,9), (2,2),

View File

@ -853,14 +853,14 @@ GROUP "/" {
}
}
ATTRIBUTE "reference" {
DATATYPE H5T_REFERENCE
DATATYPE H5T_REFERENCE { H5T_STD_REF_OBJECT }
DATASPACE SIMPLE { ( 2 ) / ( 2 ) }
DATA {
(0): DATASET 976 /dset , DATASET 976 /dset
}
}
ATTRIBUTE "reference2D" {
DATATYPE H5T_REFERENCE
DATATYPE H5T_REFERENCE { H5T_STD_REF_OBJECT }
DATASPACE SIMPLE { ( 3, 2 ) / ( 3, 2 ) }
DATA {
(0,0): DATASET 976 /dset , DATASET 976 /dset ,
@ -869,7 +869,7 @@ GROUP "/" {
}
}
ATTRIBUTE "reference3D" {
DATATYPE H5T_REFERENCE
DATATYPE H5T_REFERENCE { H5T_STD_REF_OBJECT }
DATASPACE SIMPLE { ( 4, 3, 2 ) / ( 4, 3, 2 ) }
DATA {
(0,0,0): DATASET 976 /dset , DATASET 976 /dset ,
@ -1817,14 +1817,14 @@ GROUP "/" {
}
}
DATASET "reference" {
DATATYPE H5T_REFERENCE
DATATYPE H5T_REFERENCE { H5T_STD_REF_OBJECT }
DATASPACE SIMPLE { ( 2 ) / ( 2 ) }
DATA {
(0): DATASET 976 /dset , DATASET 976 /dset
}
}
DATASET "reference2D" {
DATATYPE H5T_REFERENCE
DATATYPE H5T_REFERENCE { H5T_STD_REF_OBJECT }
DATASPACE SIMPLE { ( 3, 2 ) / ( 3, 2 ) }
DATA {
(0,0): DATASET 976 /dset , DATASET 976 /dset ,
@ -1833,7 +1833,7 @@ GROUP "/" {
}
}
DATASET "reference3D" {
DATATYPE H5T_REFERENCE
DATATYPE H5T_REFERENCE { H5T_STD_REF_OBJECT }
DATASPACE SIMPLE { ( 4, 3, 2 ) / ( 4, 3, 2 ) }
DATA {
(0,0,0): DATASET 976 /dset , DATASET 976 /dset ,