mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-08-13 20:26:03 +08:00
make casts explicit and fixed the type
This commit is contained in:
parent
ea2c02060c
commit
4e629b3c1b
@ -57,8 +57,9 @@ template<typename Scalar> void check_histogram(Scalar x, Scalar y, int bins)
|
|||||||
EIGEN_DECLARE_TEST(rand)
|
EIGEN_DECLARE_TEST(rand)
|
||||||
{
|
{
|
||||||
long long_ref = NumTraits<long>::highest()/10;
|
long long_ref = NumTraits<long>::highest()/10;
|
||||||
signed char char_offset = (std::min)(g_repeat,64);
|
// the minimum guarantees that these conversions are safe
|
||||||
signed char short_offset = (std::min)(g_repeat,16000);
|
auto char_offset = static_cast<signed char>((std::min)(g_repeat, 64));
|
||||||
|
auto short_offset = static_cast<signed short>((std::min)(g_repeat, 8000));
|
||||||
|
|
||||||
for(int i = 0; i < g_repeat*10000; i++) {
|
for(int i = 0; i < g_repeat*10000; i++) {
|
||||||
CALL_SUBTEST(check_in_range<float>(10,11));
|
CALL_SUBTEST(check_in_range<float>(10,11));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user