summaryrefslogtreecommitdiffstats
path: root/test/enum.c
diff options
context:
space:
mode:
authorRobb Matzke <matzke@llnl.gov>1999-02-25 15:40:27 (GMT)
committerRobb Matzke <matzke@llnl.gov>1999-02-25 15:40:27 (GMT)
commit17535fbc174978ae71d916a02ee4dacee66a9d8c (patch)
treed3114488ba01370e6b21acca5915c4f771125713 /test/enum.c
parentd8b07ce1d025e3f4284c5038347097180fc2da11 (diff)
downloadhdf5-17535fbc174978ae71d916a02ee4dacee66a9d8c.zip
hdf5-17535fbc174978ae71d916a02ee4dacee66a9d8c.tar.gz
hdf5-17535fbc174978ae71d916a02ee4dacee66a9d8c.tar.bz2
[svn-r1101] Changes since 19990219
---------------------- ./config/irix64 The old (-32) compiler is now supported by setting envrionment CC='cc -32'. The -64 compiler is the default or you can set CC='cc -64'. ./src/H5A.c ./src/H5D.c ./src/H5F.c ./src/H5Fistore.c ./src/H5Flow.c ./src/H5G.c ./src/H5I.c ./src/H5Ocomp.c ./src/H5P.c ./src/H5R.c ./src/H5RA.c ./src/H5T.c ./src/H5Tbit.c ./src/H5Tconv.c ./src/H5Z.c ./src/H5detect.c ./test/big.c ./test/cmpd_dset.c ./test/dsets.c ./test/dtypes.c ./test/enum.c ./test/mtime.c ./test/ohdr.c ./tools/h5ls.c Fixed lots of warnings on Irix64. Mailed a few remaining warnings in H5S to Quincey and a few in the dumper to Ruey-Hsia.
Diffstat (limited to 'test/enum.c')
-rw-r--r--test/enum.c24
1 files changed, 13 insertions, 11 deletions
diff --git a/test/enum.c b/test/enum.c
index e7e08b9..71fc4bf 100644
--- a/test/enum.c
+++ b/test/enum.c
@@ -191,7 +191,8 @@ test_tr1(hid_t file)
{
hid_t cwg=-1, m_type=-1, f_type=-1, space=-1, dset=-1;
hsize_t i, ds_size[1]={10};
- c_e1 val;
+ c_e1 eval;
+ int ival;
static c_e1 data1[10]={E1_RED, E1_GREEN, E1_BLUE, E1_GREEN, E1_WHITE,
E1_WHITE, E1_BLACK, E1_GREEN, E1_BLUE, E1_RED};
c_e1 data2[10];
@@ -200,18 +201,19 @@ test_tr1(hid_t file)
if ((cwg=H5Gcreate(file, "test_tr1", 0))<0) goto error;
if ((m_type = H5Tcreate(H5T_ENUM, sizeof(c_e1)))<0) goto error;
- if (H5Tenum_insert(m_type, "RED", CPTR(val, E1_RED ))<0) goto error;
- if (H5Tenum_insert(m_type, "GREEN", CPTR(val, E1_GREEN))<0) goto error;
- if (H5Tenum_insert(m_type, "BLUE", CPTR(val, E1_BLUE ))<0) goto error;
- if (H5Tenum_insert(m_type, "WHITE", CPTR(val, E1_WHITE))<0) goto error;
- if (H5Tenum_insert(m_type, "BLACK", CPTR(val, E1_BLACK))<0) goto error;
+ if (H5Tenum_insert(m_type, "RED", CPTR(eval, E1_RED ))<0) goto error;
+ if (H5Tenum_insert(m_type, "GREEN", CPTR(eval, E1_GREEN))<0) goto error;
+ if (H5Tenum_insert(m_type, "BLUE", CPTR(eval, E1_BLUE ))<0) goto error;
+ if (H5Tenum_insert(m_type, "WHITE", CPTR(eval, E1_WHITE))<0) goto error;
+ if (H5Tenum_insert(m_type, "BLACK", CPTR(eval, E1_BLACK))<0) goto error;
+ assert(sizeof(c_e1)==sizeof(int));
if ((f_type = H5Tcreate(H5T_ENUM, sizeof(c_e1)))<0) goto error;
- if (H5Tenum_insert(f_type, "RED", CPTR(val, 105))<0) goto error;
- if (H5Tenum_insert(f_type, "GREEN", CPTR(val, 104))<0) goto error;
- if (H5Tenum_insert(f_type, "BLUE", CPTR(val, 103))<0) goto error;
- if (H5Tenum_insert(f_type, "WHITE", CPTR(val, 102))<0) goto error;
- if (H5Tenum_insert(f_type, "BLACK", CPTR(val, 101))<0) goto error;
+ if (H5Tenum_insert(f_type, "RED", CPTR(ival, 105))<0) goto error;
+ if (H5Tenum_insert(f_type, "GREEN", CPTR(ival, 104))<0) goto error;
+ if (H5Tenum_insert(f_type, "BLUE", CPTR(ival, 103))<0) goto error;
+ if (H5Tenum_insert(f_type, "WHITE", CPTR(ival, 102))<0) goto error;
+ if (H5Tenum_insert(f_type, "BLACK", CPTR(ival, 101))<0) goto error;
if ((space=H5Screate_simple(1, ds_size, NULL))<0) goto error;
if ((dset=H5Dcreate(cwg, "color_table", f_type, space, H5P_DEFAULT))<0)