From 0a014fd5ca01429c05cf3145d7697eec49ae23cd Mon Sep 17 00:00:00 2001 From: jzmaddock Date: Wed, 21 Jun 2023 08:56:02 +0100 Subject: [PATCH] Fix for expression template use in chebyshev.hpp. --- include/boost/math/special_functions/chebyshev.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/boost/math/special_functions/chebyshev.hpp b/include/boost/math/special_functions/chebyshev.hpp index f6139220c..2c6695446 100644 --- a/include/boost/math/special_functions/chebyshev.hpp +++ b/include/boost/math/special_functions/chebyshev.hpp @@ -77,7 +77,7 @@ inline Real chebyshev_imp(unsigned n, Real const & x, const Policy&) if (x > 1 || x < -1) { Real t = sqrt(x*x -1); - return static_cast((expt(x+t, n+1) - expt(x-t, n+1))/(2*t)); + return static_cast((expt(static_cast(x+t), n+1) - expt(static_cast(x-t), n+1))/(2*t)); } T1 = 2*x; }