From 3220eb2b93f95e7ebce01141a31196176500c618 Mon Sep 17 00:00:00 2001 From: Benoit Steiner Date: Sun, 19 Apr 2015 12:36:35 -0700 Subject: [PATCH 1/2] Fixed some compilation warnings --- unsupported/Eigen/CXX11/src/Tensor/TensorDimensions.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/unsupported/Eigen/CXX11/src/Tensor/TensorDimensions.h b/unsupported/Eigen/CXX11/src/Tensor/TensorDimensions.h index c936773bf..836daea65 100644 --- a/unsupported/Eigen/CXX11/src/Tensor/TensorDimensions.h +++ b/unsupported/Eigen/CXX11/src/Tensor/TensorDimensions.h @@ -173,11 +173,11 @@ template EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE size_t IndexOfColMajor(const array& indices) const { - return internal::fixed_size_tensor_index_linearization_helper::run(indices, *static_cast(this)); + return internal::fixed_size_tensor_index_linearization_helper::run(indices, *reinterpret_cast(this)); } template EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE size_t IndexOfRowMajor(const array& indices) const { - return internal::fixed_size_tensor_index_linearization_helper::run(indices, *static_cast(this)); + return internal::fixed_size_tensor_index_linearization_helper::run(indices, *reinterpret_cast(this)); } }; @@ -369,7 +369,7 @@ struct sizes_match_up_to_dim { template bool dimensions_match(Dims1& dims1, Dims2& dims2) { - if (internal::array_size::value != internal::array_size::value) { + if (static_cast(internal::array_size::value) != static_cast(internal::array_size::value)) { return false; } return internal::sizes_match_up_to_dim::value-1>::run(dims1, dims2); From 70bc3b0668f8c2d04ab4347c6b58fca88f4a5b0e Mon Sep 17 00:00:00 2001 From: Benoit Steiner Date: Sun, 19 Apr 2015 12:38:00 -0700 Subject: [PATCH 2/2] Silenced a warning in the tensor code --- unsupported/Eigen/CXX11/src/Tensor/TensorRef.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/unsupported/Eigen/CXX11/src/Tensor/TensorRef.h b/unsupported/Eigen/CXX11/src/Tensor/TensorRef.h index acdbc181d..fba7b20a9 100644 --- a/unsupported/Eigen/CXX11/src/Tensor/TensorRef.h +++ b/unsupported/Eigen/CXX11/src/Tensor/TensorRef.h @@ -295,7 +295,7 @@ template class TensorRef : public TensorBase class TensorRef : public TensorBase