steven-varga / h5cpp

C++17 templates between [stl::vector | armadillo | eigen3 | ublas | blitz++] and HDF5 datasets
http://h5cpp.org
Other
142 stars 32 forks source link

Fix some compiler errors and warnings #72

Closed knoepfel closed 3 years ago

knoepfel commented 3 years ago

As detected using GCC 8.2. These changes address some sign-comparison, unused-variable, unused-type alias, and other minor warnings.

Sorry for some of the whitespace changes. Let me know if you'd like me to reformat.

steven-varga commented 3 years ago

Can you please post the examples that demonstrates the COMPILER ERRORS as well as an example and compiler flags for the warnings. I will be using spack install gcc@8.2.0+strip languages=c++ ...

steven-varga commented 3 years ago

didn't receive requested example that demonstrates the compile error. As for the PR: some type mismatch corrected are valid; however the PR has severe impact:

I would strongly discourage randomly removing lines. This PR section disables RAII

    ~hid_t(){
                        /* ::herr_t err = 0; */
            if( H5Iis_valid( handle ) )
                          /* err = */ capi_close( handle );
        }
knoepfel commented 3 years ago

Sorry Steven, I've been slow at getting to this...been busy. I do not believe the PR disabled RAII at all--the only thing that is commented is the err variable declaration and assignment --capi_close is still called.