diff options
author | Dana Robinson <43805+derobins@users.noreply.github.com> | 2023-09-05 18:50:06 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-05 18:50:06 (GMT) |
commit | ae1379094b71c51342772397af5caca088862a61 (patch) | |
tree | e79cb67a1227bfdec099f62e9df22917213b8a7d /tools/lib/h5tools_dump.c | |
parent | d24f5d5223731d507b51d112ba564d764d6d6c18 (diff) | |
download | hdf5-ae1379094b71c51342772397af5caca088862a61.zip hdf5-ae1379094b71c51342772397af5caca088862a61.tar.gz hdf5-ae1379094b71c51342772397af5caca088862a61.tar.bz2 |
hbool_t/TRUE/FALSE --> bool/true/false in tools (#3491)
Diffstat (limited to 'tools/lib/h5tools_dump.c')
-rw-r--r-- | tools/lib/h5tools_dump.c | 422 |
1 files changed, 211 insertions, 211 deletions
diff --git a/tools/lib/h5tools_dump.c b/tools/lib/h5tools_dump.c index 2986de7..7c221f5 100644 --- a/tools/lib/h5tools_dump.c +++ b/tools/lib/h5tools_dump.c @@ -248,7 +248,7 @@ h5tools_dump_simple_data(FILE *stream, const h5tool_format_t *info, h5tools_cont unsigned char *mem = (unsigned char *)_mem; hsize_t i; /* element counter */ size_t size; /* size of each datum */ - hbool_t dimension_break = TRUE; + bool dimension_break = true; size_t ncols = 80; /* available output width */ h5tools_str_t buffer; /* string into which to render */ hsize_t curr_pos = 0; /* total data element position */ @@ -299,7 +299,7 @@ h5tools_dump_simple_data(FILE *stream, const h5tool_format_t *info, h5tools_cont dimension_break = h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, ncols, i, elmt_counter); /* Render the data element end*/ - if (FALSE == dimension_break) + if (false == dimension_break) elmt_counter = 0; } /* end for (i = 0; i < nelmts... */ H5TOOLS_DEBUG("data render finish"); @@ -334,7 +334,7 @@ h5tools_dump_simple_data(FILE *stream, const h5tool_format_t *info, h5tools_cont * hsize_t elmt_count is the data element loop counter *------------------------------------------------------------------------- */ -hbool_t +bool h5tools_dump_region_attribute(hid_t region_id, FILE *stream, const h5tool_format_t *info, h5tools_context_t *ctx, /* in,out */ h5tools_str_t *buffer, /* string into which to render */ @@ -342,13 +342,13 @@ h5tools_dump_region_attribute(hid_t region_id, FILE *stream, const h5tool_format size_t ncols, hsize_t region_elmt_counter, /* element counter */ hsize_t elmt_counter) { - hbool_t dimension_break = TRUE; + bool dimension_break = true; hid_t atype = H5I_INVALID_HID; hid_t type_id = H5I_INVALID_HID; hid_t region_space = H5I_INVALID_HID; h5tool_format_t outputformat; /* Use to disable prefix for DATA attribute display */ - hbool_t past_catch = FALSE; - hbool_t ret_value = TRUE; + bool past_catch = false; + bool ret_value = true; assert(info); assert(ctx); @@ -379,16 +379,16 @@ h5tools_dump_region_attribute(hid_t region_id, FILE *stream, const h5tool_format H5TOOLS_GOTO_ERROR(dimension_break, "H5Tget_native_type failed"); ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the datatype element begin */ h5tools_str_reset(buffer); h5tools_str_append(buffer, "%s %s ", h5tools_dump_header_format->datatypebegin, h5tools_dump_header_format->datatypeblockbegin); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; ctx->indent_level++; - h5tools_print_datatype(stream, buffer, info, ctx, atype, TRUE); + h5tools_print_datatype(stream, buffer, info, ctx, atype, true); ctx->indent_level--; if (HDstrlen(h5tools_dump_header_format->datatypeblockend)) { @@ -403,7 +403,7 @@ h5tools_dump_region_attribute(hid_t region_id, FILE *stream, const h5tool_format h5tools_render_element(stream, info, ctx, buffer, curr_pos, ncols, region_elmt_counter, elmt_counter); /* Render the datatype element end */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the dataspace element begin */ h5tools_str_reset(buffer); @@ -424,9 +424,9 @@ h5tools_dump_region_attribute(hid_t region_id, FILE *stream, const h5tool_format /* Render the dataspace element end */ if (region_output) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; - h5tools_dump_data(stream, &outputformat, ctx, region_id, FALSE); + h5tools_dump_data(stream, &outputformat, ctx, region_id, false); } done: @@ -440,7 +440,7 @@ done: H5TOOLS_ERROR(dimension_break, "H5Sclose failed"); ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the region } element begin */ h5tools_str_reset(buffer); @@ -482,7 +482,7 @@ h5tools_print_region_data_blocks(hid_t region_id, FILE *stream, const h5tool_for size_t ncols, unsigned ndims, hid_t type_id, hsize_t nblocks, hsize_t *ptdata) { - hbool_t dimension_break = TRUE; + bool dimension_break = true; hsize_t *dims1 = NULL; hsize_t *start = NULL; hsize_t *count = NULL; @@ -495,7 +495,7 @@ h5tools_print_region_data_blocks(hid_t region_id, FILE *stream, const h5tool_for hsize_t numindex; unsigned indx; unsigned jndx; - hbool_t past_catch = FALSE; + bool past_catch = false; size_t type_size; hid_t mem_space = H5I_INVALID_HID; hid_t sid1 = H5I_INVALID_HID; @@ -551,7 +551,7 @@ h5tools_print_region_data_blocks(hid_t region_id, FILE *stream, const h5tool_for ctx.prev_multiline = cur_ctx->prev_multiline; ctx.ndims = ndims; for (blkndx = 0; blkndx < nblocks; blkndx++) { - ctx.need_prefix = TRUE; + ctx.need_prefix = true; ctx.cur_elmt = 0; for (indx = 0; indx < ndims; indx++) { start[indx] = ptdata[indx + blkndx * ndims * 2]; @@ -600,7 +600,7 @@ h5tools_print_region_data_blocks(hid_t region_id, FILE *stream, const h5tool_for ncols, ptdata, numindex, elmtno); /* Render the region data element end */ - if (FALSE == dimension_break) + if (false == dimension_break) elmtno = 0; } /* end for (numindex = 0; numindex < numelem; numindex++, elmtno++, ctx.cur_elmt++) */ } @@ -658,7 +658,7 @@ done: * hsize_t elmt_count is the data element loop counter *------------------------------------------------------------------------- */ -hbool_t +bool h5tools_dump_region_data_blocks(hid_t region_space, hid_t region_id, FILE *stream, const h5tool_format_t *info, h5tools_context_t *ctx, /* in,out */ h5tools_str_t *buffer, /* string into which to render */ @@ -666,7 +666,7 @@ h5tools_dump_region_data_blocks(hid_t region_space, hid_t region_id, FILE *strea size_t ncols, hsize_t region_elmt_counter, /* element counter */ hsize_t elmt_counter) { - hbool_t dimension_break = TRUE; + bool dimension_break = true; hssize_t snblocks; hsize_t nblocks; hsize_t alloc_size; @@ -677,8 +677,8 @@ h5tools_dump_region_data_blocks(hid_t region_space, hid_t region_id, FILE *strea hid_t dtype = H5I_INVALID_HID; hid_t type_id = H5I_INVALID_HID; h5tool_format_t outputformat; /* Use to disable prefix for DATA attribute display */ - hbool_t past_catch = FALSE; - hbool_t ret_value = TRUE; + bool past_catch = false; + bool ret_value = true; assert(info); assert(ctx); @@ -711,7 +711,7 @@ h5tools_dump_region_data_blocks(hid_t region_space, hid_t region_id, FILE *strea /* Render the region { element end */ ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the region datatype info and indices element begin */ h5tools_str_reset(buffer); @@ -749,7 +749,7 @@ h5tools_dump_region_data_blocks(hid_t region_space, hid_t region_id, FILE *strea h5tools_render_element(stream, info, ctx, buffer, curr_pos, ncols, region_elmt_counter, elmt_counter); /* Render the region datatype info and indices element end */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; if ((dtype = H5Dget_type(region_id)) < 0) H5TOOLS_GOTO_ERROR(dimension_break, "H5Dget_type failed"); @@ -762,7 +762,7 @@ h5tools_dump_region_data_blocks(hid_t region_space, hid_t region_id, FILE *strea h5tools_dump_header_format->datatypeblockbegin); ctx->indent_level++; - h5tools_print_datatype(stream, buffer, info, ctx, dtype, TRUE); + h5tools_print_datatype(stream, buffer, info, ctx, dtype, true); ctx->indent_level--; if (HDstrlen(h5tools_dump_header_format->datatypeblockend)) { @@ -777,7 +777,7 @@ h5tools_dump_region_data_blocks(hid_t region_space, hid_t region_id, FILE *strea h5tools_render_element(stream, info, ctx, buffer, curr_pos, ncols, region_elmt_counter, elmt_counter); /* Render the datatype element end */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the dataspace element begin */ h5tools_str_reset(buffer); @@ -798,7 +798,7 @@ h5tools_dump_region_data_blocks(hid_t region_space, hid_t region_id, FILE *strea /* Render the dataspace element end */ if (region_output) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the databegin element begin */ h5tools_str_reset(buffer); @@ -808,7 +808,7 @@ h5tools_dump_region_data_blocks(hid_t region_space, hid_t region_id, FILE *strea region_elmt_counter, elmt_counter); /* Render the databegin element end */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_print_region_data_blocks(region_id, rawdatastream, info, ctx, buffer, ncols, ndims, type_id, nblocks, ptdata); @@ -824,7 +824,7 @@ done: H5TOOLS_ERROR(dimension_break, "H5Tclose failed"); if (region_output) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the dataend element begin */ h5tools_str_reset(buffer); @@ -842,7 +842,7 @@ done: } ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the region } element begin */ h5tools_str_reset(buffer); @@ -884,7 +884,7 @@ h5tools_print_region_data_points(hid_t region_space, hid_t region_id, FILE *stre h5tools_str_t *buffer, size_t ncols, unsigned ndims, hid_t type_id, hsize_t npoints, hsize_t *ptdata) { - hbool_t dimension_break = TRUE; + bool dimension_break = true; hsize_t *dims1 = NULL; hsize_t elmtno; /* element index */ hsize_t curr_pos = 0; @@ -896,7 +896,7 @@ h5tools_print_region_data_points(hid_t region_space, hid_t region_id, FILE *stre hid_t mem_space = H5I_INVALID_HID; void *region_buf = NULL; h5tools_context_t ctx; - hbool_t past_catch = FALSE; + bool past_catch = false; int ret_value = 0; assert(info); @@ -936,7 +936,7 @@ h5tools_print_region_data_points(hid_t region_space, hid_t region_id, FILE *stre H5TOOLS_DEBUG("data render start:%ld", npoints); elmtno = 0; for (jndx = 0; jndx < npoints; jndx++, elmtno++) { - ctx.need_prefix = TRUE; + ctx.need_prefix = true; ctx.cur_elmt = 0; /* points are always 0 */ ctx.indent_level++; @@ -974,7 +974,7 @@ h5tools_print_region_data_points(hid_t region_space, hid_t region_id, FILE *stre dimension_break = h5tools_render_region_element(stream, info, &ctx, buffer, &curr_pos, ncols, ptdata, (hsize_t)0, elmtno); /* Render the point element end */ - if (FALSE == dimension_break) + if (false == dimension_break) elmtno = 0; } else { @@ -1019,13 +1019,13 @@ done: * hsize_t elmt_count is the data element loop counter *------------------------------------------------------------------------- */ -hbool_t +bool h5tools_dump_region_data_points(hid_t region_space, hid_t region_id, FILE *stream, const h5tool_format_t *info, h5tools_context_t *ctx, h5tools_str_t *buffer, hsize_t *curr_pos, size_t ncols, hsize_t region_elmt_counter, hsize_t elmt_counter) { - hbool_t dimension_break = TRUE; + bool dimension_break = true; hssize_t snpoints; hsize_t npoints; hsize_t alloc_size; @@ -1036,8 +1036,8 @@ h5tools_dump_region_data_points(hid_t region_space, hid_t region_id, FILE *strea hid_t dtype = H5I_INVALID_HID; hid_t type_id = H5I_INVALID_HID; h5tool_format_t outputformat; /* Use to disable prefix for DATA attribute display */ - hbool_t past_catch = FALSE; - hbool_t ret_value = TRUE; + bool past_catch = false; + bool ret_value = true; assert(info); assert(ctx); @@ -1070,7 +1070,7 @@ h5tools_dump_region_data_points(hid_t region_space, hid_t region_id, FILE *strea /* Render the region { element end */ ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the region datatype info and indices element begin */ h5tools_str_reset(buffer); @@ -1103,7 +1103,7 @@ h5tools_dump_region_data_points(hid_t region_space, hid_t region_id, FILE *strea h5tools_render_element(stream, info, ctx, buffer, curr_pos, ncols, region_elmt_counter, elmt_counter); /* Render the region datatype info and indices element end */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; if ((dtype = H5Dget_type(region_id)) < 0) H5TOOLS_GOTO_ERROR(dimension_break, "H5Dget_type failed"); @@ -1116,7 +1116,7 @@ h5tools_dump_region_data_points(hid_t region_space, hid_t region_id, FILE *strea h5tools_dump_header_format->datatypeblockbegin); ctx->indent_level++; - h5tools_print_datatype(stream, buffer, info, ctx, dtype, TRUE); + h5tools_print_datatype(stream, buffer, info, ctx, dtype, true); ctx->indent_level--; if (HDstrlen(h5tools_dump_header_format->datatypeblockend)) { @@ -1131,7 +1131,7 @@ h5tools_dump_region_data_points(hid_t region_space, hid_t region_id, FILE *strea h5tools_render_element(stream, info, ctx, buffer, curr_pos, ncols, region_elmt_counter, elmt_counter); /* Render the datatype element end */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the dataspace element begin */ h5tools_str_reset(buffer); @@ -1152,7 +1152,7 @@ h5tools_dump_region_data_points(hid_t region_space, hid_t region_id, FILE *strea /* Render the dataspace element end */ if (region_output) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the databegin element begin */ h5tools_str_reset(buffer); @@ -1163,7 +1163,7 @@ h5tools_dump_region_data_points(hid_t region_space, hid_t region_id, FILE *strea dimension_break = h5tools_render_element(stream, info, ctx, buffer, curr_pos, ncols, region_elmt_counter, elmt_counter); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_print_region_data_points(region_space, region_id, rawdatastream, info, ctx, buffer, ncols, ndims, type_id, npoints, ptdata); @@ -1179,7 +1179,7 @@ done: H5TOOLS_ERROR(dimension_break, "H5Tclose failed"); if (region_output) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the dataend element begin */ h5tools_str_reset(buffer); @@ -1197,7 +1197,7 @@ done: } ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; /* Render the region } element begin */ h5tools_str_reset(buffer); @@ -1271,7 +1271,7 @@ h5tools_print_simple_subset(FILE *stream, const h5tool_format_t *info, h5tools_c hid_t sm_space = H5I_INVALID_HID; /* stripmine data space */ hsize_t size_row_block; /* size for blocks along rows */ hsize_t row_counter = 0; - hbool_t past_catch = FALSE; + bool past_catch = false; /* VL data special information */ unsigned int vl_data = 0; /* contains VL datatypes */ herr_t ret_value = SUCCEED; @@ -1283,8 +1283,8 @@ h5tools_print_simple_subset(FILE *stream, const h5tool_format_t *info, h5tools_c size_row_block = ctx->sset->block.data[row_dim]; /* Check if we have VL data in the dataset's datatype */ - if (h5tools_detect_vlen(p_type) == TRUE) - vl_data = TRUE; + if (h5tools_detect_vlen(p_type) == true) + vl_data = true; /* display loop */ for (; hyperslab_count > 0; temp_start[row_dim] += temp_stride[row_dim], hyperslab_count--) { @@ -1364,7 +1364,7 @@ h5tools_print_simple_subset(FILE *stream, const h5tool_format_t *info, h5tools_c } ctx->sm_pos += low[ctx->ndims - 1]; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; if (h5tools_dump_simple_data(stream, info, ctx, dset, flags, sm_nelmts, p_type, sm_buf) < 0) H5TOOLS_THROW(FAIL, "h5tools_dump_simple_data failed"); @@ -1566,7 +1566,7 @@ h5tools_dump_simple_subset(FILE *stream, const h5tool_format_t *info, h5tools_co int sndims; hid_t f_space = H5I_INVALID_HID; /* file data space */ hsize_t total_size[H5S_MAX_RANK]; /* total size of dataset*/ - hbool_t past_catch = FALSE; + bool past_catch = false; herr_t ret_value = SUCCEED; H5TOOLS_START_DEBUG(" "); @@ -1624,7 +1624,7 @@ h5tools_dump_simple_dset(FILE *stream, const h5tool_format_t *info, h5tools_cont hsize_t zero[8]; /* vector of zeros */ unsigned int flags; /* buffer extent flags */ hsize_t total_size[H5S_MAX_RANK]; /* total size of dataset*/ - hbool_t past_catch = FALSE; + bool past_catch = false; /* Print info */ size_t p_type_nbytes; /* size of memory type */ @@ -1679,8 +1679,8 @@ h5tools_dump_simple_dset(FILE *stream, const h5tool_format_t *info, h5tools_cont } /* Check if we have VL data in the dataset's datatype */ - if (h5tools_detect_vlen(p_type) == TRUE) - vl_data = TRUE; + if (h5tools_detect_vlen(p_type) == true) + vl_data = true; /* * Determine the strip mine size and allocate a buffer. The strip mine is @@ -1805,7 +1805,7 @@ h5tools_dump_simple_mem(FILE *stream, const h5tool_format_t *info, h5tools_conte unsigned i; /* counters */ hsize_t total_size[H5S_MAX_RANK]; /* total size of dataset*/ hsize_t p_nelmts; /* total selected elmts */ - hbool_t past_catch = FALSE; + bool past_catch = false; unsigned char *buf = NULL; /* buffer for raw data */ int ret_value = 0; @@ -1844,8 +1844,8 @@ h5tools_dump_simple_mem(FILE *stream, const h5tool_format_t *info, h5tools_conte H5_LEAVE(SUCCEED); /* nothing to print */ /* Check if we have VL data in the dataset's datatype */ - if (h5tools_detect_vlen(p_type) == TRUE) - vl_data = TRUE; + if (h5tools_detect_vlen(p_type) == true) + vl_data = true; alloc_size = p_nelmts * H5Tget_size(p_type); assert(alloc_size == (hsize_t)((size_t)alloc_size)); /*check for overflow*/ @@ -2062,8 +2062,8 @@ h5tools_print_datatype(FILE *stream, h5tools_str_t *buffer, const h5tool_format_ H5T_order_t order; H5T_class_t type_class; H5T_sign_t sign; /* sign scheme value */ - htri_t is_vlstr = FALSE; - hbool_t past_catch = FALSE; + htri_t is_vlstr = false; + bool past_catch = false; const char *sign_s = NULL; /* sign scheme string */ const char *order_s = NULL; /* byte order string */ int ret_value = 0; @@ -2102,57 +2102,57 @@ h5tools_print_datatype(FILE *stream, h5tools_str_t *buffer, const h5tool_format_ switch (type_class) { case H5T_INTEGER: - if (H5Tequal(type, H5T_STD_I8BE) == TRUE) + if (H5Tequal(type, H5T_STD_I8BE) == true) h5tools_str_append(buffer, "H5T_STD_I8BE"); - else if (H5Tequal(type, H5T_STD_I8LE) == TRUE) + else if (H5Tequal(type, H5T_STD_I8LE) == true) h5tools_str_append(buffer, "H5T_STD_I8LE"); - else if (H5Tequal(type, H5T_STD_I16BE) == TRUE) + else if (H5Tequal(type, H5T_STD_I16BE) == true) h5tools_str_append(buffer, "H5T_STD_I16BE"); - else if (H5Tequal(type, H5T_STD_I16LE) == TRUE) + else if (H5Tequal(type, H5T_STD_I16LE) == true) h5tools_str_append(buffer, "H5T_STD_I16LE"); - else if (H5Tequal(type, H5T_STD_I32BE) == TRUE) + else if (H5Tequal(type, H5T_STD_I32BE) == true) h5tools_str_append(buffer, "H5T_STD_I32BE"); - else if (H5Tequal(type, H5T_STD_I32LE) == TRUE) + else if (H5Tequal(type, H5T_STD_I32LE) == true) h5tools_str_append(buffer, "H5T_STD_I32LE"); - else if (H5Tequal(type, H5T_STD_I64BE) == TRUE) + else if (H5Tequal(type, H5T_STD_I64BE) == true) h5tools_str_append(buffer, "H5T_STD_I64BE"); - else if (H5Tequal(type, H5T_STD_I64LE) == TRUE) + else if (H5Tequal(type, H5T_STD_I64LE) == true) h5tools_str_append(buffer, "H5T_STD_I64LE"); - else if (H5Tequal(type, H5T_STD_U8BE) == TRUE) + else if (H5Tequal(type, H5T_STD_U8BE) == true) h5tools_str_append(buffer, "H5T_STD_U8BE"); - else if (H5Tequal(type, H5T_STD_U8LE) == TRUE) + else if (H5Tequal(type, H5T_STD_U8LE) == true) h5tools_str_append(buffer, "H5T_STD_U8LE"); - else if (H5Tequal(type, H5T_STD_U16BE) == TRUE) + else if (H5Tequal(type, H5T_STD_U16BE) == true) h5tools_str_append(buffer, "H5T_STD_U16BE"); - else if (H5Tequal(type, H5T_STD_U16LE) == TRUE) + else if (H5Tequal(type, H5T_STD_U16LE) == true) h5tools_str_append(buffer, "H5T_STD_U16LE"); - else if (H5Tequal(type, H5T_STD_U32BE) == TRUE) + else if (H5Tequal(type, H5T_STD_U32BE) == true) h5tools_str_append(buffer, "H5T_STD_U32BE"); - else if (H5Tequal(type, H5T_STD_U32LE) == TRUE) + else if (H5Tequal(type, H5T_STD_U32LE) == true) h5tools_str_append(buffer, "H5T_STD_U32LE"); - else if (H5Tequal(type, H5T_STD_U64BE) == TRUE) + else if (H5Tequal(type, H5T_STD_U64BE) == true) h5tools_str_append(buffer, "H5T_STD_U64BE"); - else if (H5Tequal(type, H5T_STD_U64LE) == TRUE) + else if (H5Tequal(type, H5T_STD_U64LE) == true) h5tools_str_append(buffer, "H5T_STD_U64LE"); - else if (H5Tequal(type, H5T_NATIVE_SCHAR) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_SCHAR) == true) h5tools_str_append(buffer, "H5T_NATIVE_SCHAR"); - else if (H5Tequal(type, H5T_NATIVE_UCHAR) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_UCHAR) == true) h5tools_str_append(buffer, "H5T_NATIVE_UCHAR"); - else if (H5Tequal(type, H5T_NATIVE_SHORT) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_SHORT) == true) h5tools_str_append(buffer, "H5T_NATIVE_SHORT"); - else if (H5Tequal(type, H5T_NATIVE_USHORT) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_USHORT) == true) h5tools_str_append(buffer, "H5T_NATIVE_USHORT"); - else if (H5Tequal(type, H5T_NATIVE_INT) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_INT) == true) h5tools_str_append(buffer, "H5T_NATIVE_INT"); - else if (H5Tequal(type, H5T_NATIVE_UINT) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_UINT) == true) h5tools_str_append(buffer, "H5T_NATIVE_UINT"); - else if (H5Tequal(type, H5T_NATIVE_LONG) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_LONG) == true) h5tools_str_append(buffer, "H5T_NATIVE_LONG"); - else if (H5Tequal(type, H5T_NATIVE_ULONG) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_ULONG) == true) h5tools_str_append(buffer, "H5T_NATIVE_ULONG"); - else if (H5Tequal(type, H5T_NATIVE_LLONG) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_LLONG) == true) h5tools_str_append(buffer, "H5T_NATIVE_LLONG"); - else if (H5Tequal(type, H5T_NATIVE_ULLONG) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_ULLONG) == true) h5tools_str_append(buffer, "H5T_NATIVE_ULLONG"); else { @@ -2190,21 +2190,21 @@ h5tools_print_datatype(FILE *stream, h5tools_str_t *buffer, const h5tool_format_ break; case H5T_FLOAT: - if (H5Tequal(type, H5T_IEEE_F32BE) == TRUE) + if (H5Tequal(type, H5T_IEEE_F32BE) == true) h5tools_str_append(buffer, "H5T_IEEE_F32BE"); - else if (H5Tequal(type, H5T_IEEE_F32LE) == TRUE) + else if (H5Tequal(type, H5T_IEEE_F32LE) == true) h5tools_str_append(buffer, "H5T_IEEE_F32LE"); - else if (H5Tequal(type, H5T_IEEE_F64BE) == TRUE) + else if (H5Tequal(type, H5T_IEEE_F64BE) == true) h5tools_str_append(buffer, "H5T_IEEE_F64BE"); - else if (H5Tequal(type, H5T_IEEE_F64LE) == TRUE) + else if (H5Tequal(type, H5T_IEEE_F64LE) == true) h5tools_str_append(buffer, "H5T_IEEE_F64LE"); - else if (H5Tequal(type, H5T_VAX_F32) == TRUE) + else if (H5Tequal(type, H5T_VAX_F32) == true) h5tools_str_append(buffer, "H5T_VAX_F32"); - else if (H5Tequal(type, H5T_VAX_F64) == TRUE) + else if (H5Tequal(type, H5T_VAX_F64) == true) h5tools_str_append(buffer, "H5T_VAX_F64"); - else if (H5Tequal(type, H5T_NATIVE_FLOAT) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_FLOAT) == true) h5tools_str_append(buffer, "H5T_NATIVE_FLOAT"); - else if (H5Tequal(type, H5T_NATIVE_DOUBLE) == TRUE) + else if (H5Tequal(type, H5T_NATIVE_DOUBLE) == true) h5tools_str_append(buffer, "H5T_NATIVE_DOUBLE"); else { /* print what the library knows */ @@ -2250,7 +2250,7 @@ h5tools_print_datatype(FILE *stream, h5tools_str_t *buffer, const h5tool_format_ ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); @@ -2261,7 +2261,7 @@ h5tools_print_datatype(FILE *stream, h5tools_str_t *buffer, const h5tool_format_ h5tools_render_element(stream, info, ctx, buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); @@ -2301,7 +2301,7 @@ h5tools_print_datatype(FILE *stream, h5tools_str_t *buffer, const h5tool_format_ h5tools_render_element(stream, info, ctx, buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); @@ -2340,7 +2340,7 @@ h5tools_print_datatype(FILE *stream, h5tools_str_t *buffer, const h5tool_format_ h5tools_render_element(stream, info, ctx, buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); @@ -2415,7 +2415,7 @@ found_string_type: (hsize_t)0); ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); if (H5Tclose(str_type) < 0) @@ -2427,21 +2427,21 @@ found_string_type: break; case H5T_BITFIELD: - if (H5Tequal(type, H5T_STD_B8BE) == TRUE) + if (H5Tequal(type, H5T_STD_B8BE) == true) h5tools_str_append(buffer, "H5T_STD_B8BE"); - else if (H5Tequal(type, H5T_STD_B8LE) == TRUE) + else if (H5Tequal(type, H5T_STD_B8LE) == true) h5tools_str_append(buffer, "H5T_STD_B8LE"); - else if (H5Tequal(type, H5T_STD_B16BE) == TRUE) + else if (H5Tequal(type, H5T_STD_B16BE) == true) h5tools_str_append(buffer, "H5T_STD_B16BE"); - else if (H5Tequal(type, H5T_STD_B16LE) == TRUE) + else if (H5Tequal(type, H5T_STD_B16LE) == true) h5tools_str_append(buffer, "H5T_STD_B16LE"); - else if (H5Tequal(type, H5T_STD_B32BE) == TRUE) + else if (H5Tequal(type, H5T_STD_B32BE) == true) h5tools_str_append(buffer, "H5T_STD_B32BE"); - else if (H5Tequal(type, H5T_STD_B32LE) == TRUE) + else if (H5Tequal(type, H5T_STD_B32LE) == true) h5tools_str_append(buffer, "H5T_STD_B32LE"); - else if (H5Tequal(type, H5T_STD_B64BE) == TRUE) + else if (H5Tequal(type, H5T_STD_B64BE) == true) h5tools_str_append(buffer, "H5T_STD_B64BE"); - else if (H5Tequal(type, H5T_STD_B64LE) == TRUE) + else if (H5Tequal(type, H5T_STD_B64LE) == true) h5tools_str_append(buffer, "H5T_STD_B64LE"); else h5tools_str_append(buffer, "undefined bitfield"); @@ -2458,7 +2458,7 @@ found_string_type: if (NULL == (ttag = H5Tget_tag(type))) H5TOOLS_THROW((-1), "H5Tget_tag failed"); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); h5tools_str_append(buffer, "OPAQUE_TAG \"%s\";", ttag); @@ -2468,7 +2468,7 @@ found_string_type: H5free_memory(ttag); if ((size = H5Tget_size(type)) <= 0) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); h5tools_str_append(buffer, "OPAQUE_SIZE \"%zu\";", size); @@ -2478,7 +2478,7 @@ found_string_type: } ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); h5tools_str_append(buffer, "%s", h5tools_dump_header_format->opaqblockend); @@ -2497,10 +2497,10 @@ found_string_type: for (i = 0; i < nmembers; i++) { mname = H5Tget_member_name(type, i); if ((mtype = H5Tget_member_type(type, i)) >= 0) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); - h5tools_print_datatype(stream, buffer, info, ctx, mtype, TRUE); + h5tools_print_datatype(stream, buffer, info, ctx, mtype, true); h5tools_str_append(buffer, " \"%s\";", mname); h5tools_render_element(stream, info, ctx, buffer, &curr_pos, (size_t)ncols, (hsize_t)0, @@ -2514,7 +2514,7 @@ found_string_type: } ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); h5tools_str_append(buffer, "%s", h5tools_dump_header_format->cmpdblockend); @@ -2522,13 +2522,13 @@ found_string_type: case H5T_REFERENCE: h5tools_str_append(buffer, "%s", h5tools_dump_header_format->refblockbegin); - if (H5Tequal(type, H5T_STD_REF_DSETREG) == TRUE) { + if (H5Tequal(type, H5T_STD_REF_DSETREG) == true) { h5tools_str_append(buffer, "H5T_STD_REF_DSETREG"); } - else if (H5Tequal(type, H5T_STD_REF_OBJ) == TRUE) { + else if (H5Tequal(type, H5T_STD_REF_OBJ) == true) { h5tools_str_append(buffer, "H5T_STD_REF_OBJECT"); } - else if (H5Tequal(type, H5T_STD_REF) == TRUE) { + else if (H5Tequal(type, H5T_STD_REF) == true) { h5tools_str_append(buffer, "H5T_STD_REF"); } else { @@ -2546,10 +2546,10 @@ found_string_type: (hsize_t)0); ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); - h5tools_print_datatype(stream, buffer, info, ctx, super, TRUE); + h5tools_print_datatype(stream, buffer, info, ctx, super, true); if (H5Tclose(super) < 0) H5TOOLS_ERROR((-1), "H5Tclose failed"); @@ -2562,7 +2562,7 @@ found_string_type: ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); h5tools_str_append(buffer, "%s", h5tools_dump_header_format->enumblockend); @@ -2575,7 +2575,7 @@ found_string_type: h5tools_str_append(buffer, "%s", h5tools_dump_header_format->vlenblockbegin); - h5tools_print_datatype(stream, buffer, info, ctx, super, TRUE); + h5tools_print_datatype(stream, buffer, info, ctx, super, true); if (H5Tclose(super) < 0) H5TOOLS_ERROR((-1), "H5Tclose failed"); @@ -2607,7 +2607,7 @@ found_string_type: /* Get array base type */ if ((super = H5Tget_super(type)) >= 0) { /* Print base type */ - h5tools_print_datatype(stream, buffer, info, ctx, super, TRUE); + h5tools_print_datatype(stream, buffer, info, ctx, super, true); /* Close array base type */ if (H5Tclose(super) < 0) H5TOOLS_ERROR((-1), "H5Tclose failed"); @@ -2649,7 +2649,7 @@ h5tools_print_dataspace(h5tools_str_t *buffer, hid_t space) hsize_t maxsize[H5TOOLS_DUMP_MAX_RANK]; int ndims = -1; H5S_class_t space_type = -1; - hbool_t past_catch = FALSE; + bool past_catch = false; int i; int ret_value = 0; @@ -2738,7 +2738,7 @@ h5tools_print_enum(FILE *stream, h5tools_str_t *buffer, const h5tool_format_t *i size_t dst_size; /*destination value type size */ size_t ncols = 80; /*available output width */ hsize_t curr_pos = 0; /* total data element position */ - hbool_t past_catch = FALSE; + bool past_catch = false; int ret_value = 0; H5TOOLS_START_DEBUG(" "); @@ -2802,7 +2802,7 @@ h5tools_print_enum(FILE *stream, h5tools_str_t *buffer, const h5tool_format_t *i for (i = 0; i < nmembs; i++) { int nchars; /*number of output characters */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_simple_prefix(stream, info, ctx, (hsize_t)0, 0); h5tools_str_reset(buffer); @@ -2885,12 +2885,12 @@ h5tools_dump_datatype(FILE *stream, const h5tool_format_t *info, h5tools_context if (info->line_ncols > 0) ncols = info->line_ncols; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s ", h5tools_dump_header_format->datatypebegin, h5tools_dump_header_format->datatypeblockbegin); - h5tools_print_datatype(stream, &buffer, info, ctx, type, TRUE); + h5tools_print_datatype(stream, &buffer, info, ctx, type, true); if (HDstrlen(h5tools_dump_header_format->datatypeblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datatypeblockend); if (HDstrlen(h5tools_dump_header_format->datatypeend)) @@ -2931,7 +2931,7 @@ h5tools_dump_dataspace(FILE *stream, const h5tool_format_t *info, h5tools_contex if (info->line_ncols > 0) ncols = info->line_ncols; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s ", h5tools_dump_header_format->dataspacebegin); @@ -2978,7 +2978,7 @@ h5tools_dump_oid(FILE *stream, const h5tool_format_t *info, h5tools_context_t *c if (info->line_ncols > 0) ncols = info->line_ncols; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s %" PRId64 " %s", OBJID, BEGIN, oid, END); @@ -3004,7 +3004,7 @@ h5tools_print_virtual_selection(hid_t vspace, FILE *stream, const h5tool_format_ { switch (H5Sget_select_type(vspace)) { case H5S_SEL_NONE: /* Nothing selected */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); h5tools_str_append(buffer, "%s", VDS_NONE); @@ -3017,7 +3017,7 @@ h5tools_print_virtual_selection(hid_t vspace, FILE *stream, const h5tool_format_ h5tools_str_append(buffer, " %s", h5tools_dump_header_format->virtualselectionblockend); break; case H5S_SEL_HYPERSLABS: /* "New-style" hyperslab selection defined */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); if (H5Sis_regular_hyperslab(vspace)) { @@ -3035,7 +3035,7 @@ h5tools_print_virtual_selection(hid_t vspace, FILE *stream, const h5tool_format_ h5tools_render_element(stream, info, ctx, buffer, curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_simple_prefix(stream, info, ctx, *curr_pos, 0); h5tools_str_reset(buffer); @@ -3044,13 +3044,13 @@ h5tools_print_virtual_selection(hid_t vspace, FILE *stream, const h5tool_format_ } h5tools_render_element(stream, info, ctx, buffer, curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); h5tools_str_append(buffer, "%s", h5tools_dump_header_format->virtualselectionblockend); break; case H5S_SEL_ALL: /* Entire extent selected */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(buffer); h5tools_str_append(buffer, "%s", VDS_ALL); @@ -3082,7 +3082,7 @@ h5tools_print_fill_value(h5tools_str_t *buffer /*in,out*/, const h5tool_format_t n_type = H5Tget_native_type(type_id, H5T_DIR_DEFAULT); - if (h5tools_detect_vlen(type_id) == TRUE) + if (h5tools_detect_vlen(type_id) == true) vl_data = true; size = H5Tget_size(n_type); @@ -3160,7 +3160,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * * STORAGE_LAYOUT *------------------------------------------------------------------------- */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s", STORAGE_LAYOUT, BEGIN); @@ -3172,7 +3172,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * switch (stl) { case H5D_CHUNKED: ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s ", CHUNKED); @@ -3186,7 +3186,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); @@ -3241,14 +3241,14 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * break; case H5D_COMPACT: ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", COMPACT); h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "SIZE %" PRIuHSIZE, storage_size); @@ -3266,14 +3266,14 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * /* EXTERNAL FILE */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", CONTIGUOUS); h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s", EXTERNAL, BEGIN); @@ -3284,7 +3284,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * for (j = 0; j < (unsigned)n_external; j++) { H5Pget_external(dcpl_id, j, sizeof(name), name, &offset, &size); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "FILENAME %s SIZE %" PRIuHSIZE, name, size); @@ -3298,7 +3298,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * } ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", END); @@ -3311,14 +3311,14 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * /* NORMAL FILE */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", CONTIGUOUS); h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "SIZE %" PRIuHSIZE, storage_size); @@ -3332,7 +3332,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * if (supported & H5VL_OPT_QUERY_SUPPORTED) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); ioffset = H5Dget_offset(dset_id); @@ -3362,7 +3362,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * hid_t virtual_vspace = H5Pget_virtual_vspace(dcpl_id, curr_vmap); hid_t virtual_srcspace = H5Pget_virtual_srcspace(dcpl_id, curr_vmap); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %zu %s ", VDS_MAPPING, curr_vmap, BEGIN); @@ -3371,7 +3371,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s", VDS_VIRTUAL, BEGIN); @@ -3385,14 +3385,14 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", END); h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s", VDS_SOURCE, BEGIN); @@ -3410,7 +3410,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * assert((size_t)ssize_out < sizeof(name)); H5Pget_virtual_dsetname(dcpl_id, curr_vmap, dsetname, sizeof(dsetname)); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s", VDS_SRC_FILE, @@ -3420,7 +3420,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s", VDS_SRC_DATASET, @@ -3435,7 +3435,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", END); @@ -3444,7 +3444,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", END); @@ -3464,7 +3464,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * (hsize_t)0); } /*switch*/ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", END); @@ -3475,7 +3475,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * *------------------------------------------------------------------------- */ if (H5D_VIRTUAL != stl) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s", FILTERS, BEGIN); @@ -3492,7 +3492,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * if (filtn < 0) continue; /* nothing to print for invalid filter */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); switch (filtn) { @@ -3522,14 +3522,14 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "PIXELS_PER_BLOCK %d", szip_pixels_per_block); h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); if (szip_options_mask & H5_SZIP_CHIP_OPTION_MASK) @@ -3539,7 +3539,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); if (szip_options_mask & H5_SZIP_EC_OPTION_MASK) @@ -3549,7 +3549,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); if (szip_options_mask & H5_SZIP_LSB_OPTION_MASK) @@ -3560,7 +3560,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * (hsize_t)0, (hsize_t)0); if (szip_options_mask & H5_SZIP_RAW_OPTION_MASK) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "HEADER %s", "RAW"); @@ -3570,7 +3570,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", END); @@ -3595,7 +3595,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "FILTER_ID %d", filtn); @@ -3603,7 +3603,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * (hsize_t)0, (hsize_t)0); if (f_name[0] != '\0') { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "COMMENT %s", f_name); @@ -3611,7 +3611,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * (hsize_t)0, (hsize_t)0); } if (cd_nelmts) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s ", "PARAMS", BEGIN); @@ -3623,7 +3623,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * } ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", END); @@ -3634,7 +3634,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * } /*i*/ } /*nfilters*/ else { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "NONE"); @@ -3643,7 +3643,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * } ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", END); @@ -3654,7 +3654,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * * FILLVALUE *------------------------------------------------------------------------- */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s", FILLVALUE, BEGIN); @@ -3662,7 +3662,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "FILL_TIME "); @@ -3687,7 +3687,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * } h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s ", "VALUE "); @@ -3715,7 +3715,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", END); @@ -3726,7 +3726,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * *------------------------------------------------------------------------- */ if (H5D_VIRTUAL != stl) { - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "ALLOCATION_TIME %s", BEGIN); @@ -3734,7 +3734,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); @@ -3761,7 +3761,7 @@ h5tools_dump_dcpl(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s", END); @@ -3816,7 +3816,7 @@ h5tools_dump_comment(FILE *stream, const h5tool_format_t *info, h5tools_context_ if (cmt_bufsize > 0) { comment[cmt_bufsize] = '\0'; /* necessary because null char is not returned */ - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "COMMENT \"%s\"", comment); @@ -3858,7 +3858,7 @@ h5tools_dump_attribute(FILE *stream, const h5tool_format_t *info, h5tools_contex if (info->line_ncols > 0) ncols = info->line_ncols; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s \"%s\" %s", h5tools_dump_header_format->attributebegin, attr_name, @@ -3884,7 +3884,7 @@ h5tools_dump_attribute(FILE *stream, const h5tool_format_t *info, h5tools_contex h5tools_dump_oid(stream, info, ctx, attr_id); if (data_output || attr_data_output) - h5tools_dump_data(stream, info, ctx, attr_id, FALSE); + h5tools_dump_data(stream, info, ctx, attr_id, false); ctx->indent_level--; @@ -3893,7 +3893,7 @@ h5tools_dump_attribute(FILE *stream, const h5tool_format_t *info, h5tools_contex H5Aclose(attr_id); } - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); @@ -3946,25 +3946,25 @@ h5tools_print_packed_bits(h5tools_str_t *buffer, hid_t type) hid_t n_type = H5Tget_native_type(type, H5T_DIR_DEFAULT); if (H5Tget_class(n_type) == H5T_INTEGER) { - if (H5Tequal(n_type, H5T_NATIVE_SCHAR) == TRUE) + if (H5Tequal(n_type, H5T_NATIVE_SCHAR) == true) packed_bits_size = 8 * sizeof(char); - else if (H5Tequal(n_type, H5T_NATIVE_UCHAR) == TRUE) + else if (H5Tequal(n_type, H5T_NATIVE_UCHAR) == true) packed_bits_size = 8 * sizeof(unsigned char); - else if (H5Tequal(n_type, H5T_NATIVE_SHORT) == TRUE) + else if (H5Tequal(n_type, H5T_NATIVE_SHORT) == true) packed_bits_size = 8 * sizeof(short); - else if (H5Tequal(n_type, H5T_NATIVE_USHORT) == TRUE) + else if (H5Tequal(n_type, H5T_NATIVE_USHORT) == true) packed_bits_size = 8 * sizeof(unsigned short); - else if (H5Tequal(n_type, H5T_NATIVE_INT) == TRUE) + else if (H5Tequal(n_type, H5T_NATIVE_INT) == true) packed_bits_size = 8 * sizeof(int); - else if (H5Tequal(n_type, H5T_NATIVE_UINT) == TRUE) + else if (H5Tequal(n_type, H5T_NATIVE_UINT) == true) packed_bits_size = 8 * sizeof(unsigned int); - else if (H5Tequal(n_type, H5T_NATIVE_LONG) == TRUE) + else if (H5Tequal(n_type, H5T_NATIVE_LONG) == true) packed_bits_size = 8 * sizeof(long); - else if (H5Tequal(n_type, H5T_NATIVE_ULONG) == TRUE) + else if (H5Tequal(n_type, H5T_NATIVE_ULONG) == true) packed_bits_size = 8 * sizeof(unsigned long); - else if (H5Tequal(n_type, H5T_NATIVE_LLONG) == TRUE) + else if (H5Tequal(n_type, H5T_NATIVE_LLONG) == true) packed_bits_size = 8 * sizeof(long long); - else if (H5Tequal(n_type, H5T_NATIVE_ULLONG) == TRUE) + else if (H5Tequal(n_type, H5T_NATIVE_ULLONG) == true) packed_bits_size = 8 * sizeof(unsigned long long); else error_msg("Packed Bit not valid for this datatype"); @@ -3999,7 +3999,7 @@ h5tools_dump_subsetting_header(FILE *stream, const h5tool_format_t *info, h5tool if (info->line_ncols > 0) ncols = info->line_ncols; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s", h5tools_dump_header_format->subsettingbegin, @@ -4008,7 +4008,7 @@ h5tools_dump_subsetting_header(FILE *stream, const h5tool_format_t *info, h5tool ctx->indent_level++; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s ", h5tools_dump_header_format->startbegin, @@ -4018,7 +4018,7 @@ h5tools_dump_subsetting_header(FILE *stream, const h5tool_format_t *info, h5tool h5tools_dump_header_format->startblockend); h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s ", h5tools_dump_header_format->stridebegin, @@ -4028,7 +4028,7 @@ h5tools_dump_subsetting_header(FILE *stream, const h5tool_format_t *info, h5tool h5tools_dump_header_format->strideblockend); h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s ", h5tools_dump_header_format->countbegin, @@ -4043,7 +4043,7 @@ h5tools_dump_subsetting_header(FILE *stream, const h5tool_format_t *info, h5tool h5tools_dump_header_format->countblockend); h5tools_render_element(stream, info, ctx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s ", h5tools_dump_header_format->blockbegin, @@ -4088,7 +4088,7 @@ h5tools_dump_reference(FILE *stream, const h5tool_format_t *info, h5tools_contex datactx = *ctx; /* print context */ /* Assume entire data space to be printed */ - datactx.need_prefix = TRUE; + datactx.need_prefix = true; memset(&buffer, 0, sizeof(h5tools_str_t)); for (i = 0; i < ndims; i++, datactx.cur_elmt++, elmt_counter++) { @@ -4097,7 +4097,7 @@ h5tools_dump_reference(FILE *stream, const h5tool_format_t *info, h5tools_contex H5TOOLS_DEBUG("reference loop:%d with curr_pos=%ld", i, curr_pos); - datactx.need_prefix = TRUE; + datactx.need_prefix = true; h5tools_str_reset(&buffer); H5TOOLS_DEBUG("reference loop - h5tools_str_sprint with H5T_STD_REF:%d", i); h5tools_str_sprint(&buffer, info, container, H5T_STD_REF, &ref_buf[i], &datactx); @@ -4113,7 +4113,7 @@ h5tools_dump_reference(FILE *stream, const h5tool_format_t *info, h5tools_contex case H5O_TYPE_DATASET: if ((new_obj_id = H5Ropen_object(&ref_buf[i], H5P_DEFAULT, H5P_DEFAULT)) >= 0) { datactx.indent_level++; - h5tools_dump_data(stream, info, &datactx, new_obj_id, TRUE); + h5tools_dump_data(stream, info, &datactx, new_obj_id, true); // h5tools_dump_dset(stream, info, &datactx, new_obj_id); datactx.indent_level--; if (H5Dclose(new_obj_id) < 0) @@ -4139,7 +4139,7 @@ h5tools_dump_reference(FILE *stream, const h5tool_format_t *info, h5tools_contex H5TOOLS_DEBUG("ref_type is H5R_DATASET_REGION1"); if ((new_obj_id = H5Ropen_object(&ref_buf[i], H5P_DEFAULT, H5P_DEFAULT)) >= 0) { datactx.indent_level++; - h5tools_dump_data(stream, info, &datactx, new_obj_id, TRUE); + h5tools_dump_data(stream, info, &datactx, new_obj_id, true); // h5tools_dump_dset(stream, info, &datactx, new_obj_id); datactx.indent_level--; if (H5Dclose(new_obj_id) < 0) @@ -4158,7 +4158,7 @@ h5tools_dump_reference(FILE *stream, const h5tool_format_t *info, h5tools_contex case H5O_TYPE_DATASET: if ((new_obj_id = H5Ropen_object(&ref_buf[i], H5P_DEFAULT, H5P_DEFAULT)) >= 0) { datactx.indent_level++; - h5tools_dump_data(stream, info, &datactx, new_obj_id, TRUE); + h5tools_dump_data(stream, info, &datactx, new_obj_id, true); // h5tools_dump_dset(stream, info, &datactx, new_obj_id); datactx.indent_level--; if (H5Oclose(new_obj_id) < 0) @@ -4200,14 +4200,14 @@ h5tools_dump_reference(FILE *stream, const h5tool_format_t *info, h5tools_contex h5tools_render_element(stream, info, &datactx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - datactx.need_prefix = TRUE; + datactx.need_prefix = true; datactx.indent_level++; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "NULL"); h5tools_render_element(stream, info, &datactx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); datactx.indent_level--; - datactx.need_prefix = TRUE; + datactx.need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "}"); @@ -4260,14 +4260,14 @@ h5tools_dump_reference(FILE *stream, const h5tool_format_t *info, h5tools_contex h5tools_render_element(stream, info, &datactx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); - datactx.need_prefix = TRUE; + datactx.need_prefix = true; datactx.indent_level++; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "NULL"); h5tools_render_element(stream, info, &datactx, &buffer, &curr_pos, (size_t)ncols, (hsize_t)0, (hsize_t)0); datactx.indent_level--; - datactx.need_prefix = TRUE; + datactx.need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "}"); @@ -4297,7 +4297,7 @@ h5tools_dump_reference(FILE *stream, const h5tool_format_t *info, h5tools_contex /*------------------------------------------------------------------------- * Function: dump_data * - * Purpose: Dump attribute, obj_data is FALSE, or dataset data, obj_data is TRUE + * Purpose: Dump attribute, obj_data is false, or dataset data, obj_data is true * * Return: void *------------------------------------------------------------------------- @@ -4358,7 +4358,7 @@ h5tools_dump_data(FILE *stream, const h5tool_format_t *info, h5tools_context_t * ctx->indent_level++; } - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_str_reset(&buffer); h5tools_str_append(&buffer, "%s %s", h5tools_dump_header_format->databegin, h5tools_dump_header_format->datablockbegin); @@ -4381,7 +4381,7 @@ h5tools_dump_data(FILE *stream, const h5tool_format_t *info, h5tools_context_t * H5Sget_simple_extent_dims(space, total_size, NULL); init_acc_pos(datactx.ndims, total_size, datactx.acc, datactx.pos, datactx.p_min_idx); - datactx.need_prefix = TRUE; + datactx.need_prefix = true; if (NULL != (ref_buf = (H5R_ref_t *)calloc(MAX(sizeof(unsigned), sizeof(H5R_ref_t)), (size_t)ndims))) { @@ -4420,18 +4420,18 @@ h5tools_dump_data(FILE *stream, const h5tool_format_t *info, h5tools_context_t * */ string_dataformat.idx_fmt = "\""; datactx.indent_level++; - datactx.need_prefix = TRUE; + datactx.need_prefix = true; h5tools_simple_prefix(stream, &string_dataformat, &datactx, (hsize_t)0, 0); string_dataformat.line_multi_new = 1; string_dataformat.str_repeat = 8; - string_dataformat.ascii = TRUE; + string_dataformat.ascii = true; string_dataformat.elmt_suf1 = ""; string_dataformat.elmt_suf2 = ""; string_dataformat.line_suf = "\""; } else { - datactx.need_prefix = TRUE; + datactx.need_prefix = true; } /* Print all the values. */ @@ -4453,7 +4453,7 @@ h5tools_dump_data(FILE *stream, const h5tool_format_t *info, h5tools_context_t * if (datactx.display_char && H5Tget_size(f_type) == 1 && H5Tget_class(f_type) == H5T_INTEGER) { H5TOOLS_DEBUG("Print 1-byte integer data as an ASCII character string eol=%s", string_dataformat.line_suf); - datactx.need_prefix = FALSE; + datactx.need_prefix = false; string_dataformat.arr_linebreak = 0; string_dataformat.idx_fmt = ""; string_dataformat.line_multi_new = 0; @@ -4474,7 +4474,7 @@ done: H5Sclose(space); H5Tclose(f_type); - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_simple_prefix(stream, &outputformat, ctx, (hsize_t)0, 0); h5tools_str_reset(&buffer); @@ -4492,7 +4492,7 @@ done: if (ctx->sset && obj_data) { ctx->indent_level--; - ctx->need_prefix = TRUE; + ctx->need_prefix = true; h5tools_simple_prefix(stream, &outputformat, ctx, (hsize_t)0, 0); h5tools_str_reset(&buffer); |