Skip to content

Commit

Permalink
Committing clang-format changes
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Aug 2, 2023
1 parent f713997 commit 9d2cc56
Show file tree
Hide file tree
Showing 10 changed files with 26 additions and 20 deletions.
2 changes: 1 addition & 1 deletion src/H5Epublic.h
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ H5_DLLVAR hid_t H5E_ERR_CLS_g;
do { \
H5Epush2(H5E_DEFAULT, __FILE__, func, __LINE__, cls, maj, min, str); \
goto label; \
} while(0)
} while (0)

/**
* Error stack traversal direction
Expand Down
6 changes: 3 additions & 3 deletions src/H5FDmulti.c
Original file line number Diff line number Diff line change
Expand Up @@ -1144,9 +1144,9 @@ H5FD_multi_open(const char *name, unsigned flags, hid_t fapl_id, haddr_t maxaddr
if (H5Pclose(close_fapl) < 0)
H5Epush_goto(func, H5E_ERR_CLS, H5E_FILE, H5E_CANTCLOSEOBJ, "can't close property list", error);

/* Compute derived properties and open member files */
if (compute_next(file) < 0)
H5Epush_goto(func, H5E_ERR_CLS, H5E_INTERNAL, H5E_BADVALUE, "compute_next() failed", error);
/* Compute derived properties and open member files */
if (compute_next(file) < 0)
H5Epush_goto(func, H5E_ERR_CLS, H5E_INTERNAL, H5E_BADVALUE, "compute_next() failed", error);
if (open_members(file) < 0)
H5Epush_goto(func, H5E_ERR_CLS, H5E_INTERNAL, H5E_BADVALUE, "open_members() failed", error);

Expand Down
7 changes: 5 additions & 2 deletions test/API/tconfig.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,13 @@
vrfy_macrosize(ctype, ctype_macro, #ctype_macro); \
/* check unsigned type size */ \
vrfy_macrosize(uctype, ctype_macro, #ctype_macro); \
} while(0)
} while (0)

/* verify C type sizes: verify the sizeof type with the macro size. */
#define vrfy_ctype(type, macro) do {vrfy_macrosize(type, macro, #macro);} while(0)
#define vrfy_ctype(type, macro) \
do { \
vrfy_macrosize(type, macro, #macro); \
} while (0)

/* verify if the sizeof(type) matches size defined in macro. */
/* Needs this extra step so that we can print the macro name. */
Expand Down
8 changes: 4 additions & 4 deletions test/dtransform.c
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ const int transformData[ROWS][COLS] = {{36, 31, 25, 19, 13, 7, 1, 5, 11, 16, 22,
} \
} \
PASSED(); \
} while(0)
} while (0)

#define COMPARE(TYPE, VAR1, VAR2, TOL) \
do { \
Expand All @@ -101,7 +101,7 @@ const int transformData[ROWS][COLS] = {{36, 31, 25, 19, 13, 7, 1, 5, 11, 16, 22,
} \
} \
PASSED(); \
} while(0)
} while (0)

#define COMPARE_INT(VAR1, VAR2) \
do { \
Expand All @@ -115,7 +115,7 @@ const int transformData[ROWS][COLS] = {{36, 31, 25, 19, 13, 7, 1, 5, 11, 16, 22,
goto error; \
} \
} \
} while(0)
} while (0)

#define TEST_TYPE_CONTIG(XFORM, TYPE, HDF_TYPE, TEST_STR, COMPARE_DATA, SIGNED) \
do { \
Expand Down Expand Up @@ -211,7 +211,7 @@ const int transformData[ROWS][COLS] = {{36, 31, 25, 19, 13, 7, 1, 5, 11, 16, 22,
TEST_ERROR; \
\
free(array); \
} while(0)
} while (0)

#define TEST_TYPE_CHUNK(XFORM, TYPE, HDF_TYPE, TEST_STR, COMPARE_DATA, SIGNED) \
do { \
Expand Down
7 changes: 5 additions & 2 deletions test/tconfig.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,13 @@
vrfy_macrosize(ctype, ctype_macro, #ctype_macro); \
/* check unsigned type size */ \
vrfy_macrosize(uctype, ctype_macro, #ctype_macro); \
} while(0)
} while (0)

/* verify C type sizes: verify the sizeof type with the macro size. */
#define vrfy_ctype(type, macro) do {vrfy_macrosize(type, macro, #macro);} while(0)
#define vrfy_ctype(type, macro) \
do { \
vrfy_macrosize(type, macro, #macro); \
} while (0)

/* verify if the sizeof(type) matches size defined in macro. */
/* Needs this extra step so that we can print the macro name. */
Expand Down
2 changes: 1 addition & 1 deletion test/twriteorder.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
do { \
ret_value = val; \
goto done; \
} while(0)
} while (0)

/* type declarations */
typedef enum part_t {
Expand Down
4 changes: 2 additions & 2 deletions test/use.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@
do { \
ret_value = val; \
goto done; \
} while(0)
} while (0)
#define Hgoto_done \
do { \
goto done; \
} while(0)
} while (0)
#define Chunksize_DFT 256 /* chunksize default */
#define ErrorReportMax 10 /* max number of errors reported */
/* these two definitions must match each other */
Expand Down
2 changes: 1 addition & 1 deletion test/use_disable_mdc_flushes.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ static const char *progname_g = "use_disable_mdc_flushes"; /* program name */
do { \
ret_value = val; \
goto done; \
} while(0)
} while (0)

static char *filename_g;
static hsize_t nplanes_g;
Expand Down
4 changes: 2 additions & 2 deletions tools/src/h5perf/pio_engine.c
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,12 @@
do { \
ret_code = errcode; \
goto done; \
} while(0)
} while (0)
#define ERRMSG(mesg) \
do { \
fprintf(stderr, "Proc %d: ", pio_mpi_rank_g); \
fprintf(stderr, "*** Assertion failed (%s) at line %4d in %s\n", mesg, (int)__LINE__, __FILE__); \
} while(0)
} while (0)

/* verify: if val is false (0), print mesg. */
#define VRFY(val, mesg) \
Expand Down
4 changes: 2 additions & 2 deletions tools/src/h5perf/sio_engine.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@
do { \
ret_code = errcode; \
goto done; \
} while(0)
} while (0)
#define ERRMSG(mesg) \
do { \
fprintf(stderr, "*** Assertion failed (%s) at line %4d in %s\n", mesg, (int)__LINE__, __FILE__); \
} while(0)
} while (0)

/* verify: if val is false (0), print mesg. */
#define VRFY(val, mesg) \
Expand Down

0 comments on commit 9d2cc56

Please sign in to comment.