Browse Source

matrix: inline to prevent multiple definitions (#147)

Without inline we get multiple definitions during linking.
master
Julian Oes 5 years ago committed by GitHub
parent
commit
3a5bfb2bd1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      matrix/helper_functions.hpp

4
matrix/helper_functions.hpp

@ -65,7 +65,7 @@ Floating wrap_floating(Floating x, Floating low, Floating high) { @@ -65,7 +65,7 @@ Floating wrap_floating(Floating x, Floating low, Floating high) {
* @param high upper limit of the allowed range
* @return wrapped value inside the range
*/
float wrap(float x, float low, float high) {
inline float wrap(float x, float low, float high) {
return matrix::detail::wrap_floating(x, low, high);
}
@ -77,7 +77,7 @@ float wrap(float x, float low, float high) { @@ -77,7 +77,7 @@ float wrap(float x, float low, float high) {
* @param high upper limit of the allowed range
* @return wrapped value inside the range
*/
double wrap(double x, double low, double high) {
inline double wrap(double x, double low, double high) {
return matrix::detail::wrap_floating(x, low, high);
}

Loading…
Cancel
Save