From: Martin Kronbichler Date: Sat, 20 Apr 2024 06:08:26 +0000 (+0200) Subject: Polynomial: Make values_of_array always inline in release mode X-Git-Tag: v9.6.0-rc1~355^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F16911%2Fhead;p=dealii.git Polynomial: Make values_of_array always inline in release mode --- diff --git a/include/deal.II/base/polynomial.h b/include/deal.II/base/polynomial.h index fbf98e6ee5..44953ff56d 100644 --- a/include/deal.II/base/polynomial.h +++ b/include/deal.II/base/polynomial.h @@ -157,10 +157,13 @@ namespace Polynomials * `number` by `operator=`. */ template - void - values_of_array(const std::array &points, - const unsigned int n_derivatives, - std::array *values) const; +#ifndef DEBUG + DEAL_II_ALWAYS_INLINE +#endif + void + values_of_array(const std::array &points, + const unsigned int n_derivatives, + std::array *values) const; /** * Degree of the polynomial. This is the degree reflected by the number of @@ -863,11 +866,15 @@ namespace Polynomials template template - inline void - Polynomial::values_of_array( - const std::array &x, - const unsigned int n_derivatives, - std::array *values) const + inline +#ifndef DEBUG + DEAL_II_ALWAYS_INLINE +#endif + void + Polynomial::values_of_array( + const std::array &x, + const unsigned int n_derivatives, + std::array *values) const { // evaluate Lagrange polynomial and derivatives if (in_lagrange_product_form == true)