optimad / bitpit

Open source library for scientific HPC
http://optimad.github.io/bitpit/
GNU Lesser General Public License v3.0
115 stars 34 forks source link

RBF: fix initialization order of RBF members #438

Closed andrea-iob closed 6 months ago

andrea-iob commented 6 months ago

Fixes the following warning:

In file included from /opt/bitpit/code/src/RBF/rbf.cpp:34:0: 
/opt/bitpit/code/src/RBF/rbf.hpp: In copy constructor ‘bitpit::RBFKernel::RBFKernel(const bitpit::RBFKernel&)’: /opt/bitpit/code/src/RBF/rbf.hpp:109:22: warning: ‘bitpit::RBFKernel::m_polyActiveBasis’ will be initialized after [-Wreorder]
     std::vector<int> m_polyActiveBasis;             /**< Active terms of linear polynomial, 0 is constant, i+1 the i-th system coordinate */
                      ^~~~~~~~~~~~~~~~~
/opt/bitpit/code/src/RBF/rbf.hpp:108:22: warning:   ‘bitpit::RBFKernel::LinearPolynomial bitpit::RBFKernel::m_polynomial’ [-Wreorder]
     LinearPolynomial m_polynomial;                  /**< Linear polynomial object */
                      ^~~~~~~~~~~~
/opt/bitpit/code/src/RBF/rbf.cpp:87:1: warning:   when initialized here [-Wreorder]
 RBFKernel::RBFKernel(const RBFKernel & other)