]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Use inline functions instead of constexpr variables. 11293/head
authorWolfgang Bangerth <bangerth@colostate.edu>
Tue, 1 Dec 2020 18:39:28 +0000 (11:39 -0700)
committerWolfgang Bangerth <bangerth@colostate.edu>
Tue, 1 Dec 2020 20:10:48 +0000 (13:10 -0700)
include/deal.II/base/std_cxx17/cmath.h

index 756ba5ed6e381dfddd0e7d8fdead35f412d0a09c..6e402ac9acbe752ca1b8b9e97ebbdd72af14cd5d 100644 (file)
@@ -28,12 +28,29 @@ DEAL_II_NAMESPACE_OPEN
 namespace std_cxx17
 {
 #ifndef DEAL_II_HAVE_CXX17_BESSEL_FUNCTIONS
-  constexpr double (&cyl_bessel_j)(double, double) =
-    boost::math::cyl_bessel_j<double, double>;
-  constexpr float (&cyl_bessel_jf)(float, float) =
-    boost::math::cyl_bessel_j<float, float>;
-  constexpr long double (&cyl_bessel_jl)(long double, long double) =
-    boost::math::cyl_bessel_j<long double, long double>;
+
+  inline double
+  cyl_bessel_j(double x, double y)
+  {
+    return boost::math::cyl_bessel_j(x, y);
+  }
+
+
+
+  inline float
+  cyl_bessel_jf(float x, float y)
+  {
+    return boost::math::cyl_bessel_j(x, y);
+  }
+
+
+
+  inline long double
+  cyl_bessel_jl(long double x, long double y)
+  {
+    return boost::math::cyl_bessel_j(x, y);
+  }
+
 #else
   using std::cyl_bessel_j;
   using std::cyl_bessel_jf;

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.