diff options
author | Sean McBride <sean@rogue-research.com> | 2023-07-24 21:18:04 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-24 21:18:04 (GMT) |
commit | 553e1cd31150f7ca58f87f40d63dd8f200721611 (patch) | |
tree | 12b0aa9c90279d015bf6596e2b60d443d384c0c1 /examples/ph5example.c | |
parent | e0083c48e90beb5b56bf93eccdbfa89baa79750a (diff) | |
download | hdf5-553e1cd31150f7ca58f87f40d63dd8f200721611.zip hdf5-553e1cd31150f7ca58f87f40d63dd8f200721611.tar.gz hdf5-553e1cd31150f7ca58f87f40d63dd8f200721611.tar.bz2 |
Another round of fixing -Wextra-semi-stmt warnings (#3264)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Diffstat (limited to 'examples/ph5example.c')
-rw-r--r-- | examples/ph5example.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/examples/ph5example.c b/examples/ph5example.c index e0fc644..5ec2cdc 100644 --- a/examples/ph5example.c +++ b/examples/ph5example.c @@ -46,23 +46,25 @@ /* Define some handy debugging shorthands, routines, ... */ /* debugging tools */ #define MESG(x) \ - if (verbose) \ - printf("%s\n", x); + do { \ + if (verbose) \ + printf("%s\n", x); \ + } while (0) #define MPI_BANNER(mesg) \ - { \ + do { \ printf("--------------------------------\n"); \ printf("Proc %d: ", mpi_rank); \ printf("*** %s\n", mesg); \ printf("--------------------------------\n"); \ - } + } while (0) #define SYNC(comm) \ - { \ + do { \ MPI_BANNER("doing a SYNC"); \ MPI_Barrier(comm); \ MPI_BANNER("SYNC DONE"); \ - } + } while (0) /* End of Define some handy debugging shorthands, routines, ... */ /* Constants definitions */ |