diff options
author | Sean McBride <sean@rogue-research.com> | 2021-03-10 18:41:34 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-10 18:41:34 (GMT) |
commit | a7a013782f0af93f511142b5d167c2bc8ca8505d (patch) | |
tree | 5c13dc35b15c30315bcae04aa6971d73acabd9fc /test/error_test.c | |
parent | 7501f96ab9605e11c58bc0c9e6412e4db30ba7db (diff) | |
download | hdf5-a7a013782f0af93f511142b5d167c2bc8ca8505d.zip hdf5-a7a013782f0af93f511142b5d167c2bc8ca8505d.tar.gz hdf5-a7a013782f0af93f511142b5d167c2bc8ca8505d.tar.bz2 |
Various clang tidy warning fixes (#448)
* Fixed clang-tidy bugprone-reserved-identifier warnings
* Fixed clang-tidy bugprone-assert-side-effect warnings
* Fixed clang-tidy bugprone-copy-constructor-init warning
* Fixed clang-tidy readability-redundant-preprocessor warning
For error_test.c the removed code was already dead, because it was in the else of an `#if H5_USE_16_API` block.
Based on H5Location.h, I think p_get_ref_obj_type was meant to be in `#ifndef DOXYGEN_SHOULD_SKIP_THIS` and an `#endif` was missing. Similarly, in the header, getObjTypeByIdx is only in H5_NO_DEPRECATED_SYMBOLS, not DOXYGEN_SHOULD_SKIP_THIS.
* Fixed clang-tidy readability-redundant-string-init warnings
* Fixed some clang-tidy performance-type-promotion-in-math-fn warnings
* Fixed clang-tidy performance-unnecessary-value-param warnings
* Reformat source with clang v10.0.1.
Co-authored-by: Larry Knox <lrknox@hdfgroup.org>
Diffstat (limited to 'test/error_test.c')
-rw-r--r-- | test/error_test.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/test/error_test.c b/test/error_test.c index e294a43..9bbebec 100644 --- a/test/error_test.c +++ b/test/error_test.c @@ -129,13 +129,8 @@ test_error(hid_t file) TEST_ERROR; if (old_data != NULL) TEST_ERROR; -#ifdef H5_USE_16_API - if (old_func != (H5E_auto_t)H5Eprint) - TEST_ERROR; -#else /* H5_USE_16_API */ if (old_func != (H5E_auto2_t)H5Eprint2) TEST_ERROR; -#endif /* H5_USE_16_API */ if (H5Eset_auto2(H5E_DEFAULT, NULL, NULL) < 0) TEST_ERROR; |