Such macros are provided to facilitate application compatibility. Their use and mappings are fully described in API Compatibility Macros in HDF5; we urge you to read that document closely.
If the library and/or application is compiled for Release 1.8 or 1.10 emulation, H5O_VISIT will be mapped to H5O_VISIT1. With later versions, H5O_VISIT is mapped to H5O_VISIT2 (and H5O_VISIT1 is deprecated).
Specific compile-time compatibility flags and the resulting mappings are as follows: