From 56ea45ff0fe2facfc97c70574171f5d72b7841a8 Mon Sep 17 00:00:00 2001 From: Benoit Steiner Date: Sat, 28 Feb 2015 02:37:41 -0800 Subject: Silenced some compilation warnings --- unsupported/test/cxx11_tensor_random.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'unsupported/test/cxx11_tensor_random.cpp') diff --git a/unsupported/test/cxx11_tensor_random.cpp b/unsupported/test/cxx11_tensor_random.cpp index 8276ae822..85937ec77 100644 --- a/unsupported/test/cxx11_tensor_random.cpp +++ b/unsupported/test/cxx11_tensor_random.cpp @@ -44,7 +44,7 @@ struct MyGenerator { // location of the entry to set in the tensor, it can typically // be ignored. int operator()(Eigen::DenseIndex element_location, Eigen::DenseIndex /*unused*/ = 0) const { - return 3 * element_location; + return static_cast(3 * element_location); } // Same as above but generates several numbers at a time. @@ -53,7 +53,7 @@ struct MyGenerator { const int packetSize = internal::packet_traits::size; EIGEN_ALIGN_DEFAULT int values[packetSize]; for (int i = 0; i < packetSize; ++i) { - values[i] = 3 * (packet_location + i); + values[i] = static_cast(3 * (packet_location + i)); } return internal::pload::type>(values); } -- cgit v1.2.3