mirror of
https://github.com/HDFGroup/hdf5.git
synced 2025-03-31 17:10:47 +08:00
[svn-r18634] Description:
Clean up compiler warnings. Tested on: FreeBSD/32 6.3 (duty) in debug mode FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode Linux/32 2.6 (jam) w/PGI compilers, w/default API=1.8.x, w/C++ & FORTRAN, w/threadsafe, in debug mode Linux/64-amd64 2.6 (amani) w/Intel compilers, w/default API=1.6.x, w/C++ & FORTRAN, in production mode Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN, w/szip filter, in production mode Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN, in production mode Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in debug mode Linux/64-amd64 2.6 (abe) w/parallel, w/FORTRAN, in production mode Mac OS X/32 10.6.3 (amazon) in debug mode Mac OS X/32 10.6.3 (amazon) w/C++ & FORTRAN, w/threadsafe, in production mode
This commit is contained in:
parent
b0d7349fe8
commit
f79ab3b26b
47
configure
vendored
47
configure
vendored
@ -1,5 +1,5 @@
|
||||
#! /bin/sh
|
||||
# From configure.in Id: configure.in 18545 2010-04-11 17:03:28Z hdftest .
|
||||
# From configure.in Id: configure.in 18589 2010-04-18 13:59:45Z hdftest .
|
||||
# Guess values for system-dependent variables and create Makefiles.
|
||||
# Generated by GNU Autoconf 2.65 for HDF5 1.9.68.
|
||||
#
|
||||
@ -21345,6 +21345,17 @@ cat >>confdefs.h <<_ACEOF
|
||||
#define ssize_t long
|
||||
_ACEOF
|
||||
|
||||
fi
|
||||
|
||||
ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
|
||||
if test "x$ac_cv_type_ptrdiff_t" = x""yes; then :
|
||||
|
||||
else
|
||||
|
||||
cat >>confdefs.h <<_ACEOF
|
||||
#define ptrdiff_t long
|
||||
_ACEOF
|
||||
|
||||
fi
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
|
||||
@ -22933,6 +22944,40 @@ cat >>confdefs.h <<_ACEOF
|
||||
_ACEOF
|
||||
|
||||
|
||||
# The cast to long int works around a bug in the HP C Compiler
|
||||
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
|
||||
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
|
||||
# This bug is HP SR number 8606223364.
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of ptrdiff_t" >&5
|
||||
$as_echo_n "checking size of ptrdiff_t... " >&6; }
|
||||
if test "${ac_cv_sizeof_ptrdiff_t+set}" = set; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (ptrdiff_t))" "ac_cv_sizeof_ptrdiff_t" "$ac_includes_default"; then :
|
||||
|
||||
else
|
||||
if test "$ac_cv_type_ptrdiff_t" = yes; then
|
||||
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
|
||||
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
|
||||
{ as_fn_set_status 77
|
||||
as_fn_error "cannot compute sizeof (ptrdiff_t)
|
||||
See \`config.log' for more details." "$LINENO" 5; }; }
|
||||
else
|
||||
ac_cv_sizeof_ptrdiff_t=0
|
||||
fi
|
||||
fi
|
||||
|
||||
fi
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_ptrdiff_t" >&5
|
||||
$as_echo "$ac_cv_sizeof_ptrdiff_t" >&6; }
|
||||
|
||||
|
||||
|
||||
cat >>confdefs.h <<_ACEOF
|
||||
#define SIZEOF_PTRDIFF_T $ac_cv_sizeof_ptrdiff_t
|
||||
_ACEOF
|
||||
|
||||
|
||||
|
||||
cat >>confdefs.h <<\EOF
|
||||
#include <sys/types.h> /*for off_t definition*/
|
||||
|
@ -1333,6 +1333,7 @@ dnl
|
||||
AC_TYPE_OFF_T
|
||||
AC_CHECK_TYPE([size_t], [unsigned long])
|
||||
AC_CHECK_TYPE([ssize_t], [long])
|
||||
AC_CHECK_TYPE([ptrdiff_t], [long])
|
||||
AC_C_BIGENDIAN
|
||||
AC_CHECK_SIZEOF([char], [1])
|
||||
AC_CHECK_SIZEOF([short], [2])
|
||||
@ -1389,6 +1390,7 @@ AC_CHECK_SIZEOF( uint_fast64_t, [8])
|
||||
|
||||
AC_CHECK_SIZEOF([size_t], [4])
|
||||
AC_CHECK_SIZEOF([ssize_t], [4])
|
||||
AC_CHECK_SIZEOF([ptrdiff_t], [4])
|
||||
|
||||
cat >>confdefs.h <<\EOF
|
||||
#include <sys/types.h> /*for off_t definition*/
|
||||
|
@ -920,7 +920,7 @@ H5A_attr_copy_file(const H5A_t *attr_src, H5F_t *file_dst, hbool_t *recompute_si
|
||||
*recompute_size = TRUE;
|
||||
|
||||
/* Compute the size of the data */
|
||||
H5_ASSIGN_OVERFLOW(attr_dst->shared->data_size, H5S_GET_EXTENT_NPOINTS(attr_dst->shared->ds) * H5T_get_size(attr_dst->shared->dt), hsize_t, size_t);
|
||||
H5_ASSIGN_OVERFLOW(attr_dst->shared->data_size, H5S_GET_EXTENT_NPOINTS(attr_dst->shared->ds) * H5T_get_size(attr_dst->shared->dt), hssize_t, size_t);
|
||||
|
||||
/* Copy (& convert) the data, if necessary */
|
||||
if(attr_src->shared->data) {
|
||||
|
@ -743,7 +743,8 @@ H5B2_remove(H5B2_t *bt2, hid_t dxpl_id, void *udata, H5B2_remove_t op,
|
||||
if(H5FL_fac_term(hdr->node_info[hdr->depth].node_ptr_fac) < 0)
|
||||
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTRELEASE, FAIL, "can't destroy node's node pointer block factory")
|
||||
|
||||
hdr->depth -= (uint16_t)depth_decreased;
|
||||
HDassert((uint16_t)(hdr->depth - depth_decreased) < hdr->depth);
|
||||
hdr->depth = (uint16_t)(hdr->depth - depth_decreased);
|
||||
} /* end for */
|
||||
} /* end if */
|
||||
else {
|
||||
@ -824,7 +825,8 @@ H5B2_remove_by_idx(H5B2_t *bt2, hid_t dxpl_id, H5_iter_order_t order,
|
||||
if(H5FL_fac_term(hdr->node_info[hdr->depth].node_ptr_fac) < 0)
|
||||
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTRELEASE, FAIL, "can't destroy node's node pointer block factory")
|
||||
|
||||
hdr->depth -= (uint16_t)depth_decreased;
|
||||
HDassert((uint16_t)(hdr->depth - depth_decreased) < hdr->depth);
|
||||
hdr->depth = (uint16_t)(hdr->depth - depth_decreased);
|
||||
} /* end for */
|
||||
} /* end if */
|
||||
else {
|
||||
|
@ -1727,7 +1727,8 @@ H5D_chunk_read(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
|
||||
io_info->store->chunk.index = chunk_info->index;
|
||||
|
||||
/* Compute # of bytes accessed in chunk */
|
||||
src_accessed_bytes = chunk_info->chunk_points * type_info->src_type_size;
|
||||
H5_CHECK_OVERFLOW(type_info->src_type_size, /*From:*/ size_t, /*To:*/ uint32_t);
|
||||
src_accessed_bytes = chunk_info->chunk_points * (uint32_t)type_info->src_type_size;
|
||||
|
||||
/* Lock the chunk into the cache */
|
||||
if(NULL == (chunk = H5D_chunk_lock(io_info, &udata, FALSE, &idx_hint)))
|
||||
@ -1859,7 +1860,8 @@ H5D_chunk_write(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
|
||||
io_info->store->chunk.index = chunk_info->index;
|
||||
|
||||
/* Compute # of bytes accessed in chunk */
|
||||
dst_accessed_bytes = chunk_info->chunk_points * type_info->dst_type_size;
|
||||
H5_CHECK_OVERFLOW(type_info->dst_type_size, /*From:*/ size_t, /*To:*/ uint32_t);
|
||||
dst_accessed_bytes = chunk_info->chunk_points * (uint32_t)type_info->dst_type_size;
|
||||
|
||||
/* Determine if we will access all the data in the chunk */
|
||||
if(dst_accessed_bytes != ctg_store.contig.dset_size ||
|
||||
|
@ -172,7 +172,8 @@ done:
|
||||
static herr_t
|
||||
H5D_compact_construct(H5F_t *f, H5D_t *dset)
|
||||
{
|
||||
hssize_t tmp_size; /* Temporary holder for raw data size */
|
||||
hssize_t stmp_size; /* Temporary holder for raw data size */
|
||||
hsize_t tmp_size; /* Temporary holder for raw data size */
|
||||
hsize_t max_comp_data_size; /* Max. allowed size of compact data */
|
||||
herr_t ret_value = SUCCEED; /* Return value */
|
||||
|
||||
@ -186,7 +187,11 @@ H5D_compact_construct(H5F_t *f, H5D_t *dset)
|
||||
* Compact dataset is stored in dataset object header message of
|
||||
* layout.
|
||||
*/
|
||||
tmp_size = H5S_GET_EXTENT_NPOINTS(dset->shared->space) * H5T_get_size(dset->shared->type);
|
||||
stmp_size = H5S_GET_EXTENT_NPOINTS(dset->shared->space);
|
||||
HDassert(stmp_size >= 0);
|
||||
tmp_size = H5T_get_size(dset->shared->type);
|
||||
HDassert(tmp_size > 0);
|
||||
tmp_size = tmp_size * (hsize_t)stmp_size;
|
||||
H5_ASSIGN_OVERFLOW(dset->shared->layout.storage.u.compact.size, tmp_size, hssize_t, size_t);
|
||||
|
||||
/* Verify data size is smaller than maximum header message size
|
||||
|
64
src/H5Defl.c
64
src/H5Defl.c
@ -115,7 +115,8 @@ H5D_efl_construct(H5F_t *f, H5D_t *dset)
|
||||
size_t dt_size; /* Size of datatype */
|
||||
hsize_t dim[H5O_LAYOUT_NDIMS]; /* Current size of data in elements */
|
||||
hsize_t max_dim[H5O_LAYOUT_NDIMS]; /* Maximum size of data in elements */
|
||||
hssize_t tmp_size; /* Temporary holder for raw data size */
|
||||
hssize_t stmp_size; /* Temporary holder for raw data size */
|
||||
hsize_t tmp_size; /* Temporary holder for raw data size */
|
||||
hsize_t max_points; /* Maximum elements */
|
||||
hsize_t max_storage; /* Maximum storage size */
|
||||
int ndims; /* Rank of dataspace */
|
||||
@ -158,7 +159,9 @@ H5D_efl_construct(H5F_t *f, H5D_t *dset)
|
||||
HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "dataspace size exceeds external storage size")
|
||||
|
||||
/* Compute the total size of dataset */
|
||||
tmp_size = H5S_GET_EXTENT_NPOINTS(dset->shared->space) * dt_size;
|
||||
stmp_size = H5S_GET_EXTENT_NPOINTS(dset->shared->space);
|
||||
HDassert(stmp_size >= 0);
|
||||
tmp_size = (hsize_t)stmp_size * dt_size;
|
||||
H5_ASSIGN_OVERFLOW(dset->shared->layout.storage.u.contig.size, tmp_size, hssize_t, hsize_t);
|
||||
|
||||
/* Get the sieve buffer size for this dataset */
|
||||
@ -340,59 +343,58 @@ H5D_efl_write(const H5O_efl_t *efl, haddr_t addr, size_t size, const uint8_t *bu
|
||||
FUNC_ENTER_NOAPI_NOINIT(H5D_efl_write)
|
||||
|
||||
/* Check args */
|
||||
HDassert(efl && efl->nused>0);
|
||||
HDassert(efl && efl->nused > 0);
|
||||
HDassert(H5F_addr_defined(addr));
|
||||
HDassert(size < SIZET_MAX);
|
||||
HDassert(buf || 0 == size);
|
||||
|
||||
/* Find the first efl member in which to write */
|
||||
for (u=0, cur=0; u<efl->nused; u++) {
|
||||
if (H5O_EFL_UNLIMITED==efl->slot[u].size || addr < cur+efl->slot[u].size) {
|
||||
for(u = 0, cur = 0; u < efl->nused; u++) {
|
||||
if(H5O_EFL_UNLIMITED == efl->slot[u].size || addr < cur + efl->slot[u].size) {
|
||||
skip = addr - cur;
|
||||
break;
|
||||
}
|
||||
} /* end if */
|
||||
cur += efl->slot[u].size;
|
||||
}
|
||||
} /* end for */
|
||||
|
||||
/* Write the data */
|
||||
while (size) {
|
||||
assert(buf);
|
||||
if (u>=efl->nused)
|
||||
HGOTO_ERROR (H5E_EFL, H5E_OVERFLOW, FAIL, "write past logical end of file")
|
||||
if (H5F_OVERFLOW_HSIZET2OFFT (efl->slot[u].offset+skip))
|
||||
HGOTO_ERROR (H5E_EFL, H5E_OVERFLOW, FAIL, "external file address overflowed")
|
||||
if ((fd=HDopen (efl->slot[u].name, O_CREAT|O_RDWR, 0666))<0) {
|
||||
if (HDaccess (efl->slot[u].name, F_OK)<0) {
|
||||
HGOTO_ERROR (H5E_EFL, H5E_CANTOPENFILE, FAIL, "external raw data file does not exist")
|
||||
} else {
|
||||
HGOTO_ERROR (H5E_EFL, H5E_CANTOPENFILE, FAIL, "unable to open external raw data file")
|
||||
}
|
||||
}
|
||||
if (HDlseek (fd, (off_t)(efl->slot[u].offset+skip), SEEK_SET)<0)
|
||||
HGOTO_ERROR (H5E_EFL, H5E_SEEKERROR, FAIL, "unable to seek in external raw data file")
|
||||
while(size) {
|
||||
HDassert(buf);
|
||||
if(u >= efl->nused)
|
||||
HGOTO_ERROR(H5E_EFL, H5E_OVERFLOW, FAIL, "write past logical end of file")
|
||||
if(H5F_OVERFLOW_HSIZET2OFFT(efl->slot[u].offset + skip))
|
||||
HGOTO_ERROR(H5E_EFL, H5E_OVERFLOW, FAIL, "external file address overflowed")
|
||||
if((fd = HDopen(efl->slot[u].name, O_CREAT|O_RDWR, 0666)) < 0) {
|
||||
if(HDaccess(efl->slot[u].name, F_OK) < 0)
|
||||
HGOTO_ERROR(H5E_EFL, H5E_CANTOPENFILE, FAIL, "external raw data file does not exist")
|
||||
else
|
||||
HGOTO_ERROR(H5E_EFL, H5E_CANTOPENFILE, FAIL, "unable to open external raw data file")
|
||||
} /* end if */
|
||||
if(HDlseek(fd, (off_t)(efl->slot[u].offset + skip), SEEK_SET) < 0)
|
||||
HGOTO_ERROR(H5E_EFL, H5E_SEEKERROR, FAIL, "unable to seek in external raw data file")
|
||||
#ifndef NDEBUG
|
||||
tempto_write = MIN(efl->slot[u].size-skip,(hsize_t)size);
|
||||
H5_CHECK_OVERFLOW(tempto_write,hsize_t,size_t);
|
||||
tempto_write = MIN(efl->slot[u].size - skip, (hsize_t)size);
|
||||
H5_CHECK_OVERFLOW(tempto_write, hsize_t, size_t);
|
||||
to_write = (size_t)tempto_write;
|
||||
#else /* NDEBUG */
|
||||
to_write = MIN((size_t)(efl->slot[u].size-skip), size);
|
||||
to_write = MIN((size_t)(efl->slot[u].size - skip), size);
|
||||
#endif /* NDEBUG */
|
||||
if ((size_t)HDwrite (fd, buf, to_write)!=to_write)
|
||||
HGOTO_ERROR (H5E_EFL, H5E_READERROR, FAIL, "write error in external raw data file")
|
||||
if((size_t)HDwrite(fd, buf, to_write)!=to_write)
|
||||
HGOTO_ERROR(H5E_EFL, H5E_READERROR, FAIL, "write error in external raw data file")
|
||||
HDclose (fd);
|
||||
fd = -1;
|
||||
size -= to_write;
|
||||
buf += to_write;
|
||||
skip = 0;
|
||||
u++;
|
||||
}
|
||||
} /* end while */
|
||||
|
||||
done:
|
||||
if (fd>=0)
|
||||
HDclose (fd);
|
||||
if(fd >= 0)
|
||||
HDclose(fd);
|
||||
|
||||
FUNC_LEAVE_NOAPI(ret_value)
|
||||
}
|
||||
} /* end H5D_efl_write() */
|
||||
|
||||
|
||||
/*-------------------------------------------------------------------------
|
||||
|
@ -1852,9 +1852,9 @@ H5F_try_close(H5F_t *f)
|
||||
|
||||
/* Forced close of all opened objects in this file */
|
||||
if(f->nopen_objs > 0) {
|
||||
unsigned obj_count; /* # of open objects */
|
||||
size_t obj_count; /* # of open objects */
|
||||
hid_t objs[128]; /* Array of objects to close */
|
||||
unsigned u; /* Local index variable */
|
||||
size_t u; /* Local index variable */
|
||||
|
||||
/* Get the list of IDs of open dataset, group, & attribute objects */
|
||||
while((obj_count = H5F_get_obj_ids(f, H5F_OBJ_LOCAL|H5F_OBJ_DATASET|H5F_OBJ_GROUP|H5F_OBJ_ATTR, (int)(sizeof(objs)/sizeof(objs[0])), objs, FALSE)) != 0) {
|
||||
|
@ -459,7 +459,7 @@ H5F_super_init(H5F_t *f, hid_t dxpl_id)
|
||||
sblock->super_vers = super_vers;
|
||||
|
||||
/* Compute the size of the superblock */
|
||||
superblock_size = (size_t)H5F_SUPERBLOCK_SIZE(super_vers, f);
|
||||
superblock_size = (hsize_t)H5F_SUPERBLOCK_SIZE(super_vers, f);
|
||||
|
||||
/* Compute the size of the driver information block */
|
||||
H5_ASSIGN_OVERFLOW(driver_size, H5FD_sb_size(f->shared->lf), hsize_t, size_t);
|
||||
@ -723,7 +723,7 @@ H5F_super_size(H5F_t *f, hid_t dxpl_id, hsize_t *super_size, hsize_t *super_ext_
|
||||
|
||||
/* Set the superblock size */
|
||||
if(super_size)
|
||||
*super_size = (size_t)H5F_SUPERBLOCK_SIZE(f->shared->sblock->super_vers, f);
|
||||
*super_size = (hsize_t)H5F_SUPERBLOCK_SIZE(f->shared->sblock->super_vers, f);
|
||||
|
||||
/* Set the superblock extension size */
|
||||
if(super_ext_size) {
|
||||
|
@ -763,7 +763,7 @@ H5F_sblock_flush(H5F_t *f, hid_t dxpl_id, hbool_t destroy, haddr_t UNUSED addr,
|
||||
} /* end else */
|
||||
|
||||
/* Retrieve the total size of the superblock info */
|
||||
H5_ASSIGN_OVERFLOW(superblock_size, (p - buf), int, size_t);
|
||||
H5_ASSIGN_OVERFLOW(superblock_size, (p - buf), ptrdiff_t, size_t);
|
||||
|
||||
/* Double check we didn't overrun the block (unlikely) */
|
||||
HDassert(superblock_size <= sizeof(buf));
|
||||
|
@ -548,6 +548,9 @@
|
||||
/* The size of `off_t', as computed by sizeof. */
|
||||
#undef SIZEOF_OFF_T
|
||||
|
||||
/* The size of `ptrdiff_t', as computed by sizeof. */
|
||||
#undef SIZEOF_PTRDIFF_T
|
||||
|
||||
/* The size of `short', as computed by sizeof. */
|
||||
#undef SIZEOF_SHORT
|
||||
|
||||
@ -676,6 +679,9 @@
|
||||
/* Define to `long int' if <sys/types.h> does not define. */
|
||||
#undef off_t
|
||||
|
||||
/* Define to `long' if <sys/types.h> does not define. */
|
||||
#undef ptrdiff_t
|
||||
|
||||
/* Define to `unsigned long' if <sys/types.h> does not define. */
|
||||
#undef size_t
|
||||
|
||||
|
291
src/H5overflow.h
291
src/H5overflow.h
@ -87,6 +87,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: unsigned dst: uint64_t */
|
||||
|
||||
/* src: unsigned, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_UNSIGNED < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_unsigned_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_UNSIGNED > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_unsigned_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_UNSIGNED == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_unsigned_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: unsigned dst: ptrdiff_t */
|
||||
|
||||
/* src: unsigned, dst: size_t */
|
||||
#if H5_SIZEOF_UNSIGNED < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_unsigned_TO_size_t(dst, dsttype, src, srctype) \
|
||||
@ -222,6 +234,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: int dst: uint64_t */
|
||||
|
||||
/* src: int, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_INT < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_int_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_INT > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_int_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_INT == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_int_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: int dst: ptrdiff_t */
|
||||
|
||||
/* src: int, dst: size_t */
|
||||
#if H5_SIZEOF_INT < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_int_TO_size_t(dst, dsttype, src, srctype) \
|
||||
@ -357,6 +381,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: uint8_t dst: uint64_t */
|
||||
|
||||
/* src: uint8_t, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_UINT8_T < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_uint8_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_UINT8_T > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_uint8_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_UINT8_T == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_uint8_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: uint8_t dst: ptrdiff_t */
|
||||
|
||||
/* src: uint8_t, dst: size_t */
|
||||
#if H5_SIZEOF_UINT8_T < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_uint8_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
@ -492,6 +528,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: uint16_t dst: uint64_t */
|
||||
|
||||
/* src: uint16_t, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_UINT16_T < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_uint16_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_UINT16_T > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_uint16_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_UINT16_T == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_uint16_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: uint16_t dst: ptrdiff_t */
|
||||
|
||||
/* src: uint16_t, dst: size_t */
|
||||
#if H5_SIZEOF_UINT16_T < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_uint16_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
@ -627,6 +675,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: uint32_t dst: uint64_t */
|
||||
|
||||
/* src: uint32_t, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_UINT32_T < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_uint32_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_UINT32_T > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_uint32_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_UINT32_T == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_uint32_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: uint32_t dst: ptrdiff_t */
|
||||
|
||||
/* src: uint32_t, dst: size_t */
|
||||
#if H5_SIZEOF_UINT32_T < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_uint32_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
@ -762,6 +822,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: uint64_t dst: uint32_t */
|
||||
|
||||
/* src: uint64_t, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_UINT64_T < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_uint64_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_UINT64_T > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_uint64_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_UINT64_T == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_uint64_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: uint64_t dst: ptrdiff_t */
|
||||
|
||||
/* src: uint64_t, dst: size_t */
|
||||
#if H5_SIZEOF_UINT64_T < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_uint64_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
@ -835,6 +907,153 @@
|
||||
#endif /* src: uint64_t dst: h5_stat_size_t */
|
||||
|
||||
|
||||
/* Assignment checks for ptrdiff_t */
|
||||
|
||||
/* src: ptrdiff_t, dst: unsigned */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_UNSIGNED
|
||||
#define ASSIGN_ptrdiff_t_TO_unsigned(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_UNSIGNED
|
||||
#define ASSIGN_ptrdiff_t_TO_unsigned(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_UNSIGNED */
|
||||
#define ASSIGN_ptrdiff_t_TO_unsigned(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: unsigned */
|
||||
|
||||
/* src: ptrdiff_t, dst: int */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_INT
|
||||
#define ASSIGN_ptrdiff_t_TO_int(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_INT
|
||||
#define ASSIGN_ptrdiff_t_TO_int(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_INT */
|
||||
#define ASSIGN_ptrdiff_t_TO_int(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: int */
|
||||
|
||||
/* src: ptrdiff_t, dst: uint8_t */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_UINT8_T
|
||||
#define ASSIGN_ptrdiff_t_TO_uint8_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_UINT8_T
|
||||
#define ASSIGN_ptrdiff_t_TO_uint8_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_UINT8_T */
|
||||
#define ASSIGN_ptrdiff_t_TO_uint8_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: uint8_t */
|
||||
|
||||
/* src: ptrdiff_t, dst: uint16_t */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_UINT16_T
|
||||
#define ASSIGN_ptrdiff_t_TO_uint16_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_UINT16_T
|
||||
#define ASSIGN_ptrdiff_t_TO_uint16_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_UINT16_T */
|
||||
#define ASSIGN_ptrdiff_t_TO_uint16_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: uint16_t */
|
||||
|
||||
/* src: ptrdiff_t, dst: uint32_t */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_UINT32_T
|
||||
#define ASSIGN_ptrdiff_t_TO_uint32_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_UINT32_T
|
||||
#define ASSIGN_ptrdiff_t_TO_uint32_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_UINT32_T */
|
||||
#define ASSIGN_ptrdiff_t_TO_uint32_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: uint32_t */
|
||||
|
||||
/* src: ptrdiff_t, dst: uint64_t */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_UINT64_T
|
||||
#define ASSIGN_ptrdiff_t_TO_uint64_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_UINT64_T
|
||||
#define ASSIGN_ptrdiff_t_TO_uint64_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_UINT64_T */
|
||||
#define ASSIGN_ptrdiff_t_TO_uint64_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: uint64_t */
|
||||
|
||||
/* src: ptrdiff_t, dst: size_t */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_ptrdiff_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_ptrdiff_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_SIZE_T */
|
||||
#define ASSIGN_ptrdiff_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: size_t */
|
||||
|
||||
/* src: ptrdiff_t, dst: ssize_t */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_SSIZE_T
|
||||
#define ASSIGN_ptrdiff_t_TO_ssize_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_SSIZE_T
|
||||
#define ASSIGN_ptrdiff_t_TO_ssize_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_SSIZE_T */
|
||||
#define ASSIGN_ptrdiff_t_TO_ssize_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: ssize_t */
|
||||
|
||||
/* src: ptrdiff_t, dst: haddr_t */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_HADDR_T
|
||||
#define ASSIGN_ptrdiff_t_TO_haddr_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_HADDR_T
|
||||
#define ASSIGN_ptrdiff_t_TO_haddr_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_HADDR_T */
|
||||
#define ASSIGN_ptrdiff_t_TO_haddr_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: haddr_t */
|
||||
|
||||
/* src: ptrdiff_t, dst: hsize_t */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_HSIZE_T
|
||||
#define ASSIGN_ptrdiff_t_TO_hsize_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_HSIZE_T
|
||||
#define ASSIGN_ptrdiff_t_TO_hsize_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_HSIZE_T */
|
||||
#define ASSIGN_ptrdiff_t_TO_hsize_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: hsize_t */
|
||||
|
||||
/* src: ptrdiff_t, dst: hssize_t */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_HSSIZE_T
|
||||
#define ASSIGN_ptrdiff_t_TO_hssize_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_HSSIZE_T
|
||||
#define ASSIGN_ptrdiff_t_TO_hssize_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_HSSIZE_T */
|
||||
#define ASSIGN_ptrdiff_t_TO_hssize_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: hssize_t */
|
||||
|
||||
/* src: ptrdiff_t, dst: h5_stat_size_t */
|
||||
#if H5_SIZEOF_PTRDIFF_T < H5_SIZEOF_H5_STAT_SIZE_T
|
||||
#define ASSIGN_ptrdiff_t_TO_h5_stat_size_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_PTRDIFF_T > H5_SIZEOF_H5_STAT_SIZE_T
|
||||
#define ASSIGN_ptrdiff_t_TO_h5_stat_size_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_PTRDIFF_T == H5_SIZEOF_H5_STAT_SIZE_T */
|
||||
#define ASSIGN_ptrdiff_t_TO_h5_stat_size_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ptrdiff_t dst: h5_stat_size_t */
|
||||
|
||||
|
||||
/* Assignment checks for size_t */
|
||||
|
||||
/* src: size_t, dst: unsigned */
|
||||
@ -909,6 +1128,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: size_t dst: uint64_t */
|
||||
|
||||
/* src: size_t, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_SIZE_T < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_size_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_SIZE_T > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_size_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_SIZE_T == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_size_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: size_t dst: ptrdiff_t */
|
||||
|
||||
/* src: size_t, dst: ssize_t */
|
||||
#if H5_SIZEOF_SIZE_T < H5_SIZEOF_SSIZE_T
|
||||
#define ASSIGN_size_t_TO_ssize_t(dst, dsttype, src, srctype) \
|
||||
@ -1044,6 +1275,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ssize_t dst: uint64_t */
|
||||
|
||||
/* src: ssize_t, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_SSIZE_T < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_ssize_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_SSIZE_T > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_ssize_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_SSIZE_T == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_ssize_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: ssize_t dst: ptrdiff_t */
|
||||
|
||||
/* src: ssize_t, dst: size_t */
|
||||
#if H5_SIZEOF_SSIZE_T < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_ssize_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
@ -1179,6 +1422,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: haddr_t dst: uint64_t */
|
||||
|
||||
/* src: haddr_t, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_HADDR_T < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_haddr_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_HADDR_T > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_haddr_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_HADDR_T == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_haddr_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: haddr_t dst: ptrdiff_t */
|
||||
|
||||
/* src: haddr_t, dst: size_t */
|
||||
#if H5_SIZEOF_HADDR_T < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_haddr_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
@ -1314,6 +1569,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: hsize_t dst: uint64_t */
|
||||
|
||||
/* src: hsize_t, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_HSIZE_T < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_hsize_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_HSIZE_T > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_hsize_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_HSIZE_T == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_hsize_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: hsize_t dst: ptrdiff_t */
|
||||
|
||||
/* src: hsize_t, dst: size_t */
|
||||
#if H5_SIZEOF_HSIZE_T < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_hsize_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
@ -1449,6 +1716,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SIGNED_TO_UNSIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: hssize_t dst: uint64_t */
|
||||
|
||||
/* src: hssize_t, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_HSSIZE_T < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_hssize_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_HSSIZE_T > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_hssize_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_HSSIZE_T == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_hssize_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: hssize_t dst: ptrdiff_t */
|
||||
|
||||
/* src: hssize_t, dst: size_t */
|
||||
#if H5_SIZEOF_HSSIZE_T < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_hssize_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
@ -1584,6 +1863,18 @@
|
||||
ASSIGN_TO_SAME_SIZE_SAME_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: h5_stat_size_t dst: uint64_t */
|
||||
|
||||
/* src: h5_stat_size_t, dst: ptrdiff_t */
|
||||
#if H5_SIZEOF_H5_STAT_SIZE_T < H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_h5_stat_size_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_LARGER_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#elif H5_SIZEOF_H5_STAT_SIZE_T > H5_SIZEOF_PTRDIFF_T
|
||||
#define ASSIGN_h5_stat_size_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SMALLER_SIZE(dst, dsttype, src, srctype)
|
||||
#else /* H5_SIZEOF_H5_STAT_SIZE_T == H5_SIZEOF_PTRDIFF_T */
|
||||
#define ASSIGN_h5_stat_size_t_TO_ptrdiff_t(dst, dsttype, src, srctype) \
|
||||
ASSIGN_TO_SAME_SIZE_UNSIGNED_TO_SIGNED(dst, dsttype, src, srctype)
|
||||
#endif /* src: h5_stat_size_t dst: ptrdiff_t */
|
||||
|
||||
/* src: h5_stat_size_t, dst: size_t */
|
||||
#if H5_SIZEOF_H5_STAT_SIZE_T < H5_SIZEOF_SIZE_T
|
||||
#define ASSIGN_h5_stat_size_t_TO_size_t(dst, dsttype, src, srctype) \
|
||||
|
@ -36,6 +36,7 @@ uint8_t, UNSIGNED;
|
||||
uint16_t, UNSIGNED;
|
||||
uint32_t, UNSIGNED;
|
||||
uint64_t, UNSIGNED;
|
||||
ptrdiff_t, SIGNED;
|
||||
size_t, UNSIGNED;
|
||||
ssize_t, SIGNED;
|
||||
haddr_t, UNSIGNED;
|
||||
|
Loading…
x
Reference in New Issue
Block a user