diff options
author | Antonio Sanchez <cantonios@google.com> | 2020-11-16 10:39:09 -0800 |
---|---|---|
committer | Antonio Sanchez <cantonios@google.com> | 2020-11-16 10:39:09 -0800 |
commit | 8e9cc5b10a16dde87c65e9e9c4471095f78e11d4 (patch) | |
tree | df2c2dc47ceb10396c1428e21068c88e903530e0 /Eigen/src/Core | |
parent | 9175f50d6f88bd38789f2a9c6d4f0bfe1b8b6b37 (diff) |
Eliminate double-promotion warnings.
Clang currently complains about implicit conversions, e.g.
```
test/packetmath.cpp:680:59: warning: implicit conversion increases floating-point precision: 'typename Eigen::internal::random_retval<typename Eigen::internal::global_math_functions_filtering_base<double>::type>::type' (aka 'double') to 'long double' [-Wdouble-promotion]
data1[0] = Scalar((2 * k + k1) * EIGEN_PI / 2 * internal::random<double>(0.8, 1.2));
~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
test/packetmath.cpp:681:40: warning: implicit conversion increases floating-point precision: 'float' to 'long double' [-Wdouble-promotion]
data1[1] = Scalar((2 * k + 2 + k1) * EIGEN_PI / 2 * internal::random<double>(0.8, 1.2));
```
Modified to explicitly cast to double.
Diffstat (limited to 'Eigen/src/Core')
0 files changed, 0 insertions, 0 deletions