ess-dmsc / h5cpp

C++ wrapper for the HDF5 C-library
https://ess-dmsc.github.io/h5cpp/
GNU Lesser General Public License v2.1
116 stars 19 forks source link

Add further choices for LibVersion #649

Closed FlyingSamson closed 3 months ago

FlyingSamson commented 3 months ago

Implements #648 by adding additional choices for hdf5::property::LibVersion. The available choices are constraint based on the available version of HDF5:

One important thing to notice:
When the specific versions (V18, V110, etc.) where first introduced in v1.10.2, HDF5_LIBVER_LATEST was removed from the H5F_libver_t enum and instead #define'd to refer to the actual latest version among the now added enum values V18, V110, etc. Therefore, starting with v1.10.2 LibVersion::Latest is no longer distinguishable from the actual latest version (e.g., LibVersion::V110). I therefore removed the printing of "Latest" in favor of printing the actual version number in case LibVersion::Latest was specified. I did not see a better alternative, as the cases in this switch-statement need to remain disjoint.